/* ── FONTS ── */
@font-face {
  font-family: 'Cormorant Garamond';
  font-style: normal; font-weight: 600 700; font-display: swap;
  src: url('assets/fonts/cormorant-garamond-600-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Cormorant Garamond';
  font-style: normal; font-weight: 600 700; font-display: swap;
  src: url('assets/fonts/cormorant-garamond-600-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Cormorant Garamond';
  font-style: italic; font-weight: 600; font-display: swap;
  src: url('assets/fonts/cormorant-garamond-italic-600-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Cormorant Garamond';
  font-style: italic; font-weight: 600; font-display: swap;
  src: url('assets/fonts/cormorant-garamond-italic-600-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Outfit';
  font-style: normal; font-weight: 300 500; font-display: swap;
  src: url('assets/fonts/outfit-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Outfit';
  font-style: normal; font-weight: 300 500; font-display: swap;
  src: url('assets/fonts/outfit-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ── VARIABLES ── */
:root {
  --ink:    #141210;
  --cream:  #f8f4ee;
  --warm:   #ede8df;
  --forest: #1e3a1e;
  --ember:  #bf4e22;
  --gold:   #c9982a;
  --mist:   #ddd8ce;
}

/* ── RESET ── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--cream);
  color: var(--ink);
  font-family: 'Outfit', sans-serif;
  font-weight: 300;
  overflow-x: hidden;
}


/* ── HERO ── */
.hero {
  min-height: 100svh;
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 5rem 2rem 4rem;
  background: var(--forest);
  position: relative; overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 70% 50% at 90% 10%, rgba(201,152,42,0.18) 0%, transparent 55%),
    radial-gradient(ellipse 50% 60% at 0% 100%, rgba(191,78,34,0.12) 0%, transparent 50%);
}
.hero-deco {
  position: absolute; bottom: -0.05em; right: -0.03em;
  font-family: 'Cormorant Garamond', serif; font-weight: 700;
  font-size: clamp(18rem, 42vw, 40rem); line-height: 1;
  color: rgba(255,255,255,0.03);
  user-select: none; pointer-events: none;
}
.hero-inner { position: relative; z-index: 1; max-width: 760px; }

/* ── EYEBROW ── */
.eyebrow {
  display: flex; align-items: center; gap: 0.75rem;
  font-size: 0.67rem; font-weight: 500;
  letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 1.75rem;
}
.eyebrow::before { content: ''; width: 1.8rem; height: 1px; background: currentColor; }
.eyebrow.dark { color: var(--ember); }
.eyebrow.dark::before { background: var(--ember); }

/* ── TYPOGRAPHY ── */
h1 {
  font-family: 'Cormorant Garamond', serif; font-weight: 700;
  font-size: clamp(3rem, 9vw, 6.5rem);
  line-height: 0.95; color: var(--cream);
  letter-spacing: -0.01em; margin-bottom: 1.75rem;
}
h1 em { font-style: italic; color: var(--gold); }

h2 {
  font-family: 'Cormorant Garamond', serif; font-weight: 700;
  font-size: clamp(2rem, 5vw, 3.2rem);
  line-height: 1.05; color: var(--forest);
  letter-spacing: -0.01em; margin-bottom: 0.75rem;
}

.hero-sub {
  font-size: clamp(0.92rem, 2vw, 1.05rem); line-height: 1.8;
  color: rgba(248,244,238,0.5); max-width: 460px; margin-bottom: 2.75rem;
}
.hero-note {
  margin-top: 1.25rem;
  font-size: 0.72rem; font-weight: 500;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: rgba(248,244,238,0.3);
}
.section-lead {
  font-size: 0.92rem; line-height: 1.8;
  color: rgba(20,18,16,0.5); max-width: 540px; margin-bottom: 3.5rem;
}

/* ── BUTTONS ── */
.hero-actions { display: flex; flex-wrap: wrap; gap: 1rem; }
.btn-cream {
  display: inline-block; padding: 0.9rem 2.2rem;
  background: var(--cream); color: var(--forest);
  text-decoration: none; font-size: 0.8rem; font-weight: 500;
  letter-spacing: 0.06em; transition: background 0.2s, transform 0.15s;
}
.btn-cream:hover { background: var(--gold); color: var(--ink); transform: translateY(-1px); }
.btn-ghost {
  display: inline-block; padding: 0.9rem 2.2rem;
  border: 1px solid rgba(248,244,238,0.25); color: rgba(248,244,238,0.6);
  text-decoration: none; font-size: 0.8rem; font-weight: 400;
  letter-spacing: 0.05em; transition: border-color 0.2s, color 0.2s;
}
.btn-ghost:hover { border-color: var(--gold); color: var(--gold); }


/* ── SECTIONS ── */
section { padding: 5.5rem 2rem; }
.wrap { max-width: 1080px; margin: 0 auto; }

/* ── PROMISE CARDS ── */
.promise-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 2px; background: var(--mist);
  border: 1px solid var(--mist);
}
.promise-card {
  position: relative; overflow: hidden;
  background: var(--mist);
  aspect-ratio: 3/4;
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 2rem;
}
.promise-card img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; transition: transform 0.6s ease;
}
.promise-card:hover img { transform: scale(1.04); }
.promise-card::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(20,18,16,0.75) 0%, rgba(20,18,16,0.1) 60%, transparent 100%);
}
.promise-label {
  position: relative; z-index: 1;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.4rem; font-weight: 600;
  color: var(--cream); line-height: 1.2;
}

/* ── STUFEN ── */
.stufen { background: var(--warm); }
.stufen-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 2px; background: var(--mist);
  border: 1px solid var(--mist);
  margin-top: 3rem;
}
.stufe {
  background: var(--cream); padding: 2.2rem 1.8rem;
  display: flex; flex-direction: column; align-items: flex-start;
  transition: background 0.2s;
}
.stufe:hover { background: #fff; }
.stufe img { width: 3rem; height: 3rem; object-fit: contain; margin-bottom: 1.2rem; }
.stufe h3 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.3rem; font-weight: 600;
  color: var(--forest); margin-bottom: 0.3rem;
}
.stufe-age {
  font-size: 0.68rem; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--ember);
  font-weight: 500; margin-bottom: 0.8rem;
}
.stufe p { font-size: 0.84rem; line-height: 1.7; color: rgba(20,18,16,0.55); }

/* ── ACTIVITIES ── */
.activities { background: var(--cream); }
.activity {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 2px; background: var(--mist);
  border: 1px solid var(--mist);
  margin-bottom: 2px;
}
.activity:last-child { margin-bottom: 0; }
.activity.flip .activity-img { order: 2; }
.activity.flip .activity-text { order: 1; }
.activity-img { aspect-ratio: 16/10; overflow: hidden; }
.activity-img img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.5s ease;
}
.activity:hover .activity-img img { transform: scale(1.03); }
.activity-text {
  background: var(--cream); padding: 3rem 2.5rem;
  display: flex; flex-direction: column; justify-content: center;
}
.activity-text h3 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.7rem; font-weight: 600;
  color: var(--forest); margin-bottom: 0.9rem;
}
.activity-text p { font-size: 0.88rem; line-height: 1.8; color: rgba(20,18,16,0.55); }

/* ── AUSBILDUNG ── */
.ausbildung { background: var(--warm); }
.ausbildung-inner {
  max-width: 1080px; margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 5rem; align-items: center;
}
.ausbildung-text p {
  font-size: 0.9rem; line-height: 1.85;
  color: rgba(20,18,16,0.6); margin-bottom: 1.2rem;
}
.aus-link {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-size: 0.84rem; font-weight: 500;
  color: var(--forest); text-decoration: none;
  border-bottom: 1px solid rgba(30,58,30,0.3);
  padding-bottom: 0.15rem; transition: color 0.2s, border-color 0.2s;
}
.aus-link:hover { color: var(--ember); border-color: var(--ember); }
.aus-callout {
  background: var(--forest); padding: 3rem;
  display: flex; flex-direction: column; gap: 1.5rem;
}
.aus-callout h3 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.8rem; font-weight: 700;
  color: var(--cream); line-height: 1.1;
}
.aus-callout p { font-size: 0.86rem; line-height: 1.75; color: rgba(248,244,238,0.5); }
.aus-callout a {
  display: inline-block; padding: 0.8rem 1.8rem;
  background: var(--gold); color: var(--ink);
  text-decoration: none; font-size: 0.78rem;
  font-weight: 500; letter-spacing: 0.07em;
  align-self: flex-start; transition: background 0.2s;
}
.aus-callout a:hover { background: var(--cream); }

/* ── MAP ── */
.mapblock { background: var(--warm); scroll-margin-top: 2.5rem; }
.mapblock .eyebrow { color: var(--ember); }
.mapblock .eyebrow::before { background: var(--ember); }
.mapblock h2 { color: var(--forest); margin-bottom: 0.5rem; }
.map-sub { font-size: 0.9rem; color: rgba(20,18,16,0.5); margin-bottom: 2.5rem; }

.map-wrap {
  display: grid; grid-template-columns: 1fr 280px;
  gap: 2px; background: var(--mist);
  border: 1px solid var(--mist);
  height: 520px;
}
#map { width: 100%; height: 100%; }
.map-sidebar {
  background: rgba(20,18,16,0.92);
  overflow-y: auto; padding: 1.5rem 1.25rem;
  scrollbar-width: thin;
  scrollbar-color: rgba(201,152,42,0.4) transparent;
  position: relative;
}
.map-sidebar::-webkit-scrollbar { width: 4px; }
.map-sidebar::-webkit-scrollbar-track { background: transparent; }
.map-sidebar::-webkit-scrollbar-thumb { background: rgba(201,152,42,0.4); border-radius: 2px; }
.map-sidebar::-webkit-scrollbar-thumb:hover { background: rgba(201,152,42,0.7); }
.sidebar-title {
  font-size: 0.62rem; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--gold);
  font-weight: 500; margin-bottom: 1rem;
}
#stamm-list { list-style: none; display: flex; flex-direction: column; gap: 2px; }
#stamm-list li {
  padding: 0.7rem 0.9rem;
  background: rgba(255,255,255,0.04);
  cursor: pointer; transition: background 0.15s;
}
#stamm-list li:hover,
#stamm-list li.active { background: rgba(201,152,42,0.15); }
#stamm-list li:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
#stamm-list li .s-name {
  font-size: 0.8rem; font-weight: 500;
  color: var(--cream); display: block; margin-bottom: 0.2rem;
}
#stamm-list li .s-district {
  font-size: 0.68rem; color: rgba(248,244,238,0.6); letter-spacing: 0.05em;
}
#stamm-list li .s-boroughs {
  font-size: 0.65rem; color: rgba(248,244,238,0.4); 
  display: block; margin-top: 0.15rem; line-height: 1.3;
}
#stamm-list li.hovered {
  background: rgba(201,152,42,0.25);
  border-left: 3px solid var(--gold);
}

.stamm-external {
  list-style: none;
  margin-top: 0.5rem;
  border-top: 1px solid rgba(248,244,238,0.08);
  padding-top: 0.5rem;
}
.stamm-external a {
  display: block; padding: 0.7rem 0.9rem;
  font-size: 0.75rem; line-height: 1.5;
  color: var(--gold); text-decoration: none;
  background: rgba(201,152,42,0.07);
  transition: background 0.15s;
}
.stamm-external a:hover { background: rgba(201,152,42,0.18); }

/* Map custom controls */
.map-ctrl-group { margin-top: 6px !important; }
.map-ctrl-btn {
  display: flex; align-items: center; justify-content: center;
  width: 29px; height: 29px;
  background: var(--ink); border: none; cursor: pointer;
  color: var(--cream); padding: 5px;
}
.map-ctrl-btn:hover { background: #2a2520; }
.map-ctrl-btn svg { width: 16px; height: 16px; }
.map-ctrl-btn.locating { opacity: 0.5; cursor: default; }

/* Locate dot */
.locate-dot {
  width: 14px; height: 14px;
  background: #4a9eff; border: 2px solid #fff; border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(74,158,255,0.25);
}

/* Borough tooltip */
.map-tooltip {
  display: none;
  position: absolute;
  z-index: 10;
  pointer-events: none;
  background: var(--ink);
  border: 1px solid rgba(201,152,42,0.45);
  color: var(--cream);
  font-family: 'Outfit', sans-serif;
  font-size: 0.75rem;
  line-height: 1.4;
  padding: 0.35rem 0.6rem;
  white-space: nowrap;
}
.map-tooltip b { font-weight: 500; }
.map-tooltip span { opacity: 0.6; display: block; }

/* Map pin */
.map-pin {
  width: 14px; height: 14px;
  background: #c9982a; border: 2px solid #f8f4ee; border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(201,152,42,0.3);
  cursor: pointer; transition: transform 0.15s;
}
.map-pin:hover,
.map-pin.hovered { 
  transform: scale(1.3);
  background: #e6b545;
  box-shadow: 0 0 0 4px rgba(201,152,42,0.5);
}

/* MapLibre popup */
.maplibregl-popup-content {
  background: var(--ink) !important;
  border-radius: 0 !important;
  box-shadow: 0 4px 24px rgba(0,0,0,0.4) !important;
  border: 1px solid rgba(201,152,42,0.3) !important;
  padding: 1rem 1.2rem !important;
  font-family: 'Outfit', sans-serif;
  min-width: 170px;
}
.maplibregl-popup-tip { border-top-color: var(--ink) !important; }
.maplibregl-ctrl-attrib {
  background: rgba(237,232,223,0.85) !important;
  font-size: 0.62rem !important;
}
.popup-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.1rem; font-weight: 700;
  color: var(--cream); margin-bottom: 0.25rem;
}
.popup-district {
  font-size: 0.7rem; color: var(--gold);
  letter-spacing: 0.1em; text-transform: uppercase; margin-bottom: 0.3rem;
}
.popup-boroughs {
  font-size: 0.65rem; color: rgba(248,244,238,0.7);
  margin-bottom: 0.8rem; line-height: 1.3;
}
.popup-link {
  display: inline-block; font-size: 0.85rem; padding: 0.35rem 0;
  color: var(--gold); text-decoration: underline; text-underline-offset: 3px;
  transition: color 0.2s;
}
.popup-link:hover, .popup-link:focus-visible { color: var(--cream); }

/* ── CONTACT ── */
.contact { background: var(--ink); }
.contact-grid {
  max-width: 1080px; margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 5rem; align-items: start;
}
.contact .eyebrow { color: var(--gold); }
.contact .eyebrow::before { background: var(--gold); }
.contact h2 { color: var(--cream); margin-bottom: 1rem; }
.contact-body {
  font-size: 0.9rem; line-height: 1.8;
  color: rgba(248,244,238,0.4); margin-bottom: 2rem;
}
.contact-email {
  display: inline-flex; align-items: center; gap: 0.5rem;
  color: var(--gold); text-decoration: none; font-size: 0.88rem;
  border-bottom: 1px solid rgba(201,152,42,0.3);
  padding-bottom: 0.15rem; transition: border-color 0.2s;
}
.contact-email:hover { border-color: var(--gold); }
.contact-info { display: flex; flex-direction: column; gap: 1.8rem; margin-top: 0.5rem; }
.ci { display: flex; flex-direction: column; gap: 0.3rem; }
.ci-label {
  font-size: 0.62rem; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--ember); font-weight: 500;
}
.ci-val { font-size: 0.86rem; color: rgba(248,244,238,0.45); line-height: 1.5; }
.ci-val a { color: inherit; text-decoration: none; }
.ci-val a:hover { color: var(--gold); }

/* ── FOOTER ── */
footer {
  background: #0c0b09; padding: 1.5rem 2rem;
  display: flex; flex-wrap: wrap; gap: 1rem;
  justify-content: space-between; align-items: center;
  font-size: 0.7rem; color: rgba(248,244,238,0.22);
}
footer a { color: inherit; text-decoration: none; }
footer a:hover { color: var(--gold); }
.footer-links { display: flex; gap: 2rem; flex-wrap: wrap; }

/* ── MODAL ── */
.modal-backdrop {
  display: none; position: fixed; inset: 0; z-index: 1000;
  background: rgba(12,11,9,0.82); backdrop-filter: blur(4px);
  align-items: center; justify-content: center; padding: 1.5rem;
}
.modal-backdrop.open { display: flex; }
.modal-box {
  background: var(--ink); border: 1px solid var(--mist);
  max-width: 680px; width: 100%; max-height: 80vh;
  overflow-y: auto; padding: 2.5rem 2.5rem 2rem;
  position: relative;
  scrollbar-width: thin; scrollbar-color: rgba(201,152,42,0.4) transparent;
}
.modal-box::-webkit-scrollbar { width: 4px; }
.modal-box::-webkit-scrollbar-thumb { background: rgba(201,152,42,0.4); border-radius: 2px; }
.modal-close {
  position: absolute; top: 1rem; right: 1.25rem;
  background: none; border: none; color: var(--cream);
  font-size: 1.4rem; cursor: pointer; opacity: 0.5; line-height: 1;
}
.modal-close:hover { opacity: 1; }
.modal-body h1, .modal-body h2, .modal-body h3 {
  font-family: var(--serif); color: var(--cream); margin: 1.5rem 0 0.5rem;
}
.modal-body h1 { font-size: 1.6rem; margin-top: 0; }
.modal-body h2 { font-size: 1.15rem; }
.modal-body p { color: rgba(248,244,238,0.72); font-size: 0.88rem; line-height: 1.7; margin-bottom: 0.75rem; }
.modal-body a { color: var(--gold); }
.modal-body strong { color: var(--cream); font-weight: 500; }
@media (max-width: 700px) {
  .modal-box { padding: 2rem 1.25rem 1.5rem; }
}

/* ── REVEAL ANIMATION ── */
.r { opacity: 0; transform: translateY(18px); transition: opacity 0.6s ease, transform 0.6s ease; }
.r.on { opacity: 1; transform: none; }

/* ── RESPONSIVE ── */
@media (max-width: 960px) {
  .promise-grid { grid-template-columns: 1fr 1fr; }
  .stufen-grid { grid-template-columns: 1fr 1fr; }
  .activity { grid-template-columns: 1fr; }
  .activity.flip .activity-img { order: -1; }
  .ausbildung-inner { gap: 3rem; }
  .contact-grid { gap: 3rem; }
}

@media (max-width: 700px) {
  nav { padding: 1rem 1.25rem; }
  section { padding: 4rem 1.25rem; }
  .hero { padding: 4rem 1.25rem 3rem; }
  .promise-grid { grid-template-columns: 1fr; }
  .promise-card { aspect-ratio: 4/3; }
  .stufen-grid { grid-template-columns: 1fr 1fr; }
  .activity { grid-template-columns: 1fr; }
  .activity.flip { direction: ltr; }
  .ausbildung-inner { grid-template-columns: 1fr; gap: 2.5rem; }
  .contact-grid { grid-template-columns: 1fr; gap: 3rem; }
  .map-wrap { grid-template-columns: 1fr; height: auto; }
  #map { height: 340px; }
  .map-sidebar { max-height: 220px; }
}
