/* ==================================================================
   Club 41 Steyr — Stylesheet
   Farben und Schriftgrößen stehen gesammelt im Block :root.
   Wer dort etwas ändert, ändert es auf allen Seiten gleichzeitig.
   ================================================================== */

/* --- Schriften ----------------------------------------------------
   Liegen im Ordner fonts/ und werden vom eigenen Server geladen.
   Keine Verbindung zu Google. Beide Schriften stehen unter der
   SIL Open Font License, siehe fonts/OFL-Outfit.txt und
   fonts/OFL-Figtree.txt.
   ------------------------------------------------------------------ */

@font-face {
  font-family: "Outfit";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(fonts/outfit-latin-600-normal.woff2) format("woff2");
}

@font-face {
  font-family: "Outfit";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(fonts/outfit-latin-700-normal.woff2) format("woff2");
}

@font-face {
  font-family: "Figtree";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(fonts/figtree-latin-400-normal.woff2) format("woff2");
}

@font-face {
  font-family: "Figtree";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(fonts/figtree-latin-500-normal.woff2) format("woff2");
}

@font-face {
  font-family: "Figtree";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(fonts/figtree-latin-600-normal.woff2) format("woff2");
}

:root {
  /* Die beiden Grüntöne stammen direkt aus dem Vereinslogo */
  --petrol:      #17736A;
  --petrol-deep: #0D4741;
  --sage:        #5FA397;
  --sage-soft:   #DFEDE9;

  --ground:      #F4F7F6;
  --surface:     #FFFFFF;
  --ink:         #10322F;
  --body:        #3F5A56;
  --muted:       #6E8884;
  --line:        #DAE7E3;
  --link:        #14655E;

  --display: "Outfit", "Trebuchet MS", Verdana, sans-serif;
  --sans:    "Figtree", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;

  --wrap: 42rem;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --petrol:      #2E8B80;
    --petrol-deep: #0A2B28;
    --sage:        #74BAAE;
    --sage-soft:   #15332F;

    --ground:      #0B1A18;
    --surface:     #122624;
    --ink:         #E7F1EE;
    --body:        #B3C9C5;
    --muted:       #7E9B96;
    --line:        #1F3B37;
    --link:        #7FC6BA;
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --petrol:      #2E8B80;
  --petrol-deep: #0A2B28;
  --sage:        #74BAAE;
  --sage-soft:   #15332F;

  --ground:      #0B1A18;
  --surface:     #122624;
  --ink:         #E7F1EE;
  --body:        #B3C9C5;
  --muted:       #7E9B96;
  --line:        #1F3B37;
  --link:        #7FC6BA;
  color-scheme: dark;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--ground);
  color: var(--body);
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.65;
}

img { max-width: 100%; height: auto; }

a { color: var(--link); text-underline-offset: 3px; }
a:hover { color: var(--ink); }
a:focus-visible {
  outline: 2px solid var(--petrol);
  outline-offset: 3px;
  border-radius: 2px;
}

/* --- Markenstreifen: zitiert die Farbblöcke des Logos -------------- */

.brandbar {
  display: flex;
  height: 7px;
}

.brandbar i { flex: 1; }
.brandbar i:nth-child(odd)  { background: var(--petrol); }
.brandbar i:nth-child(even) { background: var(--sage); }
.brandbar i:nth-child(4)    { flex: 2; }

/* --- Gemeinsames Raster ------------------------------------------- */

.zone { padding-inline: 1.25rem; }

.zone > * {
  max-width: var(--wrap);
  margin-inline: auto;
}

/* Abschnitte auf Petrolgrund: Tokens lokal umdefinieren, damit jede
   Schrift darin lesbar bleibt — in hellem wie in dunklem Modus. */
.on-petrol {
  background: var(--petrol-deep);
  --ink:     #FFFFFF;
  --body:    #C4DED9;
  --muted:   #8FB8B1;
  --surface: rgba(255, 255, 255, 0.06);
  --line:    rgba(255, 255, 255, 0.16);
  --link:    #A8D9D0;
  color: var(--body);
}

/* --- Kopf mit Wortmarke ------------------------------------------- */

.masthead {
  position: relative;
  overflow: hidden;
  padding-block: clamp(2.25rem, 6vw, 3.25rem) clamp(1.75rem, 4vw, 2.5rem);
}

.masthead__inner {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.wordmark { width: min(26rem, 100%); }
.wordmark img { display: block; width: 100%; }

.wordmark--small { width: min(13rem, 60%); }

/* Kompassrose aus dem Logo als angeschnittenes Ornament.
   Als Bild eingebunden, damit sie in jedem Browser erscheint. */
.rose-mark {
  position: absolute;
  top: 50%;
  right: -8rem;
  width: 30rem;
  max-width: 55%;
  aspect-ratio: 1;
  transform: translateY(-46%);
  pointer-events: none;
  background: url(images/rose.png) center / contain no-repeat;
  opacity: 0.4;
}

:root[data-theme="dark"] .rose-mark { opacity: 0.22; }

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .rose-mark { opacity: 0.22; }
}

@media (max-width: 52rem) { .rose-mark { display: none; } }

/* --- Typografie ---------------------------------------------------- */

.label {
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--petrol);
  margin: 0;
}

.on-petrol .label { color: var(--sage); }

h1 {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2.2rem, 7vw, 3.1rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 0;
  text-wrap: balance;
}

h2 {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(1.5rem, 4vw, 1.85rem);
  line-height: 1.2;
  letter-spacing: -0.015em;
  color: var(--ink);
  margin: 0;
  text-wrap: balance;
}

h3 {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.1rem;
  line-height: 1.3;
  color: var(--ink);
  margin: 0;
}

p { margin: 0; }

.lead {
  font-size: clamp(1.075rem, 2.4vw, 1.2rem);
  line-height: 1.55;
  color: var(--body);
  max-width: 32rem;
}

.prose { max-width: 34rem; display: flex; flex-direction: column; gap: 0.85rem; }

/* --- Eckdaten als Chips -------------------------------------------- */

.chips {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.chips li {
  background: var(--sage-soft);
  color: var(--ink);
  border-radius: 999px;
  padding: 0.3rem 0.85rem;
  font-size: 0.8rem;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

.chips b { font-weight: 700; }

.on-petrol .chips li {
  background: rgba(255, 255, 255, 0.1);
  color: #FFFFFF;
}

/* --- Textabschnitte ------------------------------------------------ */

.block {
  padding-block: clamp(2.5rem, 6vw, 3.5rem);
}

.block > * > * + * { margin-top: 0; }

.stack {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.stack--wide { gap: 1.5rem; }

/* --- Trenner mit Kompassrose --------------------------------------- */

.divider {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding-block: 0.5rem;
}

.divider::before,
.divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}

.divider i {
  width: 24px;
  height: 24px;
  flex: none;
  background: url(images/rose.png) center / contain no-repeat;
}

/* --- Drei Säulen des Clublebens ------------------------------------ */

.pillars {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
  gap: 1rem;
}

.pillars li {
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 3px solid var(--sage);
  padding: 1.25rem 1.25rem 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.pillars p { font-size: 0.9375rem; color: var(--body); }

/* --- Wahlspruch ------------------------------------------------------
   Drei Schritte in fester Reihenfolge, darum nummeriert — römisch,
   wie das CXLI im Vereinszeichen.
   ------------------------------------------------------------------- */

.creed-block {
  position: relative;
  overflow: hidden;
}

.creed-block > * { position: relative; z-index: 1; }

.creed {
  list-style: none;
  margin: 0.5rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
}

.creed li {
  display: grid;
  grid-template-columns: 2.25rem minmax(0, auto) 1fr;
  align-items: baseline;
  gap: 0 1.5rem;
  padding-block: clamp(1rem, 3vw, 1.5rem);
  border-top: 1px solid rgba(255, 255, 255, 0.18);
}

.creed li:last-child { border-bottom: 1px solid rgba(255, 255, 255, 0.18); }

.creed__num {
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.06em;
  color: var(--sage);
}

.creed__word {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2rem, 7vw, 3.25rem);
  line-height: 1;
  letter-spacing: -0.03em;
  color: #FFFFFF;
}

/* Das mittlere Wort im helleren Grünton — der Farbwechsel
   der Wortmarke im Logo. */
.creed li:nth-child(2) .creed__word { color: var(--sage); }

.creed__gloss {
  font-size: 0.9375rem;
  line-height: 1.5;
  color: var(--body);
}

@media (max-width: 40rem) {
  .creed li {
    grid-template-columns: 2rem 1fr;
    gap: 0.35rem 0.85rem;
  }
  .creed__gloss { grid-column: 2; }
}

.creed-note {
  margin-top: 1.25rem;
  font-size: 0.9375rem;
  color: var(--muted);
  max-width: 34rem;
}

/* Kompassrose als Hintergrund des Wahlspruch-Blocks */
.creed-rose {
  position: absolute;
  top: 50%;
  left: -12rem;
  width: 34rem;
  aspect-ratio: 1;
  transform: translateY(-50%);
  pointer-events: none;
  background: url(images/rose.png) center / contain no-repeat;
  opacity: 0.09;
  z-index: 0;
}

@media (max-width: 60rem) { .creed-rose { display: none; } }

.source {
  font-size: 0.8125rem;
  color: var(--muted);
}

/* --- Kontakt -------------------------------------------------------- */

.mailto {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  align-self: flex-start;
  background: var(--petrol);
  color: #FFFFFF;
  text-decoration: none;
  font-family: var(--display);
  font-size: clamp(1.05rem, 3vw, 1.3rem);
  font-weight: 600;
  letter-spacing: -0.01em;
  padding: 0.8rem 1.4rem;
  border-radius: 4px;
  transition: background-color 0.18s ease, transform 0.18s ease;
  max-width: 100%;
  word-break: break-word;
}

.mailto:hover {
  background: var(--sage);
  color: #FFFFFF;
  transform: translateY(-1px);
}

.on-petrol .mailto { background: var(--sage); color: var(--petrol-deep); }
.on-petrol .mailto:hover { background: #FFFFFF; color: var(--petrol-deep); }

/* --- Verwandte Clubs ------------------------------------------------ */

.links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
}

.links li { border-top: 1px solid var(--line); }
.links li:last-child { border-bottom: 1px solid var(--line); }

.links a {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.2rem 0.75rem;
  padding: 0.85rem 0.5rem 0.85rem 0;
  text-decoration: none;
  color: var(--ink);
  font-weight: 600;
  transition: padding-left 0.18s ease, color 0.18s ease;
}

.links a:hover { color: var(--petrol); padding-left: 0.4rem; }
.links span { font-weight: 400; font-size: 0.875rem; color: var(--muted); }

/* --- Rechtstexte ---------------------------------------------------- */

.legal { display: flex; flex-direction: column; gap: 1.75rem; }

.legal section { display: flex; flex-direction: column; gap: 0.7rem; }

.legal h2 { font-size: 1.2rem; }

.legal p, .legal li { font-size: 0.9375rem; }

.datasheet {
  margin: 0;
  display: grid;
  grid-template-columns: minmax(9rem, auto) 1fr;
  gap: 0.55rem 1.5rem;
  font-size: 0.9375rem;
}

.datasheet dt {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  padding-top: 0.3rem;
}

.datasheet dd { margin: 0; color: var(--ink); }
.datasheet dd .sub { display: block; font-size: 0.875rem; color: var(--muted); }

.num { font-variant-numeric: tabular-nums; letter-spacing: 0.02em; }

@media (max-width: 30rem) {
  .datasheet { grid-template-columns: 1fr; gap: 0.1rem; }
  .datasheet dd { margin-bottom: 0.7rem; }
}

.legal ul {
  margin: 0;
  padding-left: 1.15rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

/* Merkkasten — nur für euch, vor dem Live-Gang entfernen */
.todo {
  background: var(--sage-soft);
  border-left: 3px solid var(--petrol);
  padding: 0.85rem 1rem;
  font-size: 0.875rem;
  color: var(--ink);
}

/* --- Fußzeile -------------------------------------------------------- */

.sitefoot {
  padding-block: clamp(2rem, 5vw, 2.75rem) calc(2rem + env(safe-area-inset-bottom, 0px));
}

.sitefoot__inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1rem 2rem;
  font-size: 0.875rem;
}

.sitefoot nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.sitefoot a { color: var(--link); }
.sitefoot a:hover { color: #FFFFFF; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}
