/* FabLab Hamm - member services page
   Colours and dimensions are taken from fablab-hamm.de.
   Audience: smartphones, many members aged 60+ -> large targets, large type, high contrast. */

:root {
  --blau: #364899;
  --blau-hell: #3b55ba;
  --gruen: #0e9a48;
  --text: #111827;
  --text-leise: #4b5563;
  --rand: #e5e7eb;
  --flaeche: #f9fafb;
  --weiss: #fff;

  --breite: 80rem;
  --radius: 0.75rem;
  --schrift: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
             Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  /* 18px base size - deliberately larger than the usual 16px */
  font-size: 112.5%;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--schrift);
  color: var(--text);
  background: var(--weiss);
  line-height: 1.55;
}

.container {
  width: 100%;
  max-width: var(--breite);
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* Visible only to screen readers. Absolutely positioned, so it never takes part
   in the flex layout of the link it sits in. */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- Skip link for keyboard users ---------- */

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--blau);
  color: var(--weiss);
  padding: 0.9rem 1.25rem;
  z-index: 100;
  border-radius: 0 0 var(--radius) 0;
}
.skip-link:focus { left: 0; }

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

.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--weiss);
  border-bottom: 1px solid var(--rand);
}

/* Brand gradient blue -> green as a thin edge */
.header::after {
  content: "";
  display: block;
  height: 4px;
  background: linear-gradient(to right, var(--blau), var(--gruen));
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4.5rem;
}

.header__logo { position: relative; display: flex; align-items: center; padding: 0.5rem 0; }
.header__logo img { height: 2.25rem; width: auto; display: block; }

/* ---------- Language switch ---------- */

.lang { display: flex; gap: 0.375rem; }

.lang__btn {
  font: inherit;
  font-weight: 700;
  min-width: 3.25rem;
  min-height: 3rem;
  padding: 0 0.75rem;
  color: var(--blau);
  background: var(--weiss);
  border: 2px solid var(--rand);
  border-radius: 0.5rem;
  cursor: pointer;
}
.lang__btn:hover { border-color: var(--blau-hell); }
.lang__btn[aria-pressed="true"] {
  background: var(--blau);
  border-color: var(--blau);
  color: var(--weiss);
}

/* ---------- Install hint ---------- */

.install {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1rem;
  margin: 1.5rem 0 0;
  padding: 1rem 1.25rem;
  background: var(--flaeche);
  border: 1px solid var(--rand);
  border-left: 6px solid var(--gruen);
  border-radius: var(--radius);
}
.install[hidden] { display: none; }

.install__icon {
  flex: none;
  width: 1.75rem;
  height: 1.75rem;
  fill: none;
  stroke: var(--gruen);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.install__text { flex: 1 1 14rem; margin: 0; }
.install__text[hidden] { display: none; }

.install__go {
  font: inherit;
  font-weight: 700;
  min-height: 3rem;
  padding: 0 1.25rem;
  color: var(--weiss);
  background: var(--gruen);
  border: none;
  border-radius: 0.5rem;
  cursor: pointer;
}
.install__go[hidden] { display: none; }
.install__go:hover { background: #0c8540; }

.install__close {
  font: inherit;
  min-height: 3rem;
  padding: 0 0.75rem;
  color: var(--text-leise);
  background: none;
  border: none;
  text-decoration: underline;
  cursor: pointer;
}

/* ---------- Text ---------- */

h1 {
  font-size: 1.9rem;
  line-height: 1.2;
  margin: 2rem 0 0.5rem;
}

.lead {
  margin: 0 0 1.5rem;
  color: var(--text-leise);
}

.notice {
  margin: 0 0 1.75rem;
  padding: 1rem 1.25rem;
  background: #eef1fa;
  border-left: 6px solid var(--blau);
  border-radius: var(--radius);
  font-weight: 600;
}

/* ---------- Service list ---------- */

.services {
  list-style: none;
  margin: 0 0 3rem;
  padding: 0;
  display: grid;
  gap: 0.875rem;
}

.service {
  position: relative;
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: 4.5rem;          /* ~72px tap target */
  padding: 1rem 1.125rem;
  background: var(--weiss);
  border: 2px solid var(--rand);
  border-radius: var(--radius);
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s, background-color 0.15s;
}
.service:hover { border-color: var(--blau-hell); background: var(--flaeche); }
.service:active { background: #eef1fa; }

.service__icon {
  flex: none;
  width: 2.25rem;
  height: 2.25rem;
  fill: none;
  stroke: var(--blau);
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.service__text { display: flex; flex-direction: column; flex: 1 1 auto; min-width: 0; }

.service__name {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--blau);
  line-height: 1.25;
}

.service__desc {
  font-size: 1.02rem;
  color: var(--text-leise);
  line-height: 1.45;
  margin-top: 0.15rem;
}

.service__chevron {
  flex: none;
  width: 1.75rem;
  height: 1.75rem;
  fill: none;
  stroke: var(--text-leise);
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

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

.footer {
  border-top: 4px solid transparent;
  border-image: linear-gradient(to right, var(--blau), var(--gruen)) 1;
  background: var(--flaeche);
  padding: 1.75rem 0 2.5rem;
}

.footer__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 2rem;
}

.footer__nav a {
  position: relative;
  color: var(--text-leise);
  min-height: 3rem;
  display: flex;
  align-items: center;
}
.footer__nav a:hover { color: var(--blau); }

/* ---------- Focus: identical everywhere and clearly visible ---------- */

a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--blau);
  outline-offset: 2px;
  border-radius: 0.375rem;
}

/* ---------- Desktop ---------- */

@media (min-width: 64rem) {
  .container { padding: 0 2rem; }
  .header__inner { min-height: 6rem; }
  .header__logo img { height: 2.75rem; }
  h1 { font-size: 2.4rem; margin-top: 2.5rem; }
  .services { grid-template-columns: 1fr 1fr; gap: 1rem; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}
