/* ============================================================
   Kirchenanzeige – krosa.at
   Stylesheet: Website (hell, ruhig) + eingebettete Demo (dunkel,
   Optik der echten Bedienoberfläche)
   ============================================================ */

@font-face {
  font-family: "Cormorant Garamond";
  src: url("cormorant-garamond.woff2") format("woff2");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("source-sans-3.woff2") format("woff2");
  font-weight: 200 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --stein: #f6f5f1;        /* Seitenhintergrund, heller Stein */
  --papier: #ffffff;
  --tinte: #22303c;        /* Schiefer, Fließtext */
  --tinte-leicht: #5b6570;
  --linie: #d9d6cd;
  --gruen: #2e6b4f;        /* liturgisches Grün, Aktionen */
  --gruen-dunkel: #245740;
  --gold: #b8963e;         /* Kerzenlicht, sparsame Akzente */

  /* Demo – Farben der echten App */
  --app-bg: #16213e;
  --app-bg2: #0f3460;
  --app-panel: #243354;
  --app-gruen: #00ff88;
  --app-gruen2: #00c96e;
  --app-rot: #ff4444;
  --app-orange: #ffb443;

  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Source Sans 3", "Segoe UI", system-ui, sans-serif;
  --breite: 1120px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--tinte);
  background: var(--stein);
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--gruen); }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 2px;
}

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 500;
  line-height: 1.15;
  margin: 0 0 .5em;
  color: var(--tinte);
}
h1 { font-size: clamp(2.4rem, 5vw, 3.8rem); }
h2 { font-size: clamp(1.9rem, 3.4vw, 2.6rem); }
h3 { font-size: 1.45rem; }
p { margin: 0 0 1em; max-width: 68ch; }
.klein { font-size: .9rem; color: var(--tinte-leicht); }

.container { width: min(var(--breite), 100% - 2.5rem); margin-inline: auto; }
section { padding: clamp(3rem, 7vw, 6rem) 0; }
section + section { border-top: 1px solid var(--linie); }

/* ---------- Kopf ---------- */
.kopf {
  position: sticky; top: 0; z-index: 20;
  background: rgba(246,245,241,.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--linie);
}
.kopf .container { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 64px; }
.marke { font-family: var(--serif); font-size: 1.55rem; font-weight: 600; text-decoration: none; color: var(--tinte); letter-spacing: .01em; }
.marke small { display: block; font-family: var(--sans); font-size: .72rem; font-weight: 400; color: var(--tinte-leicht); letter-spacing: .04em; margin-top: -.25em; }
.nav { display: flex; gap: 1.4rem; flex-wrap: wrap; }
.nav a { color: var(--tinte); text-decoration: none; font-weight: 500; padding: .25rem 0; border-bottom: 2px solid transparent; }
.nav a:hover { border-color: var(--gold); }
@media (max-width: 720px) { .nav { display: none; } }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block; padding: .8rem 1.5rem; border-radius: 6px;
  font: 600 1rem var(--sans); text-decoration: none; cursor: pointer;
  border: 1px solid var(--gruen); background: var(--gruen); color: #fff;
}
.btn:hover { background: var(--gruen-dunkel); }
.btn.hell { background: transparent; color: var(--gruen); }
.btn.hell:hover { background: rgba(46,107,79,.08); }
.btn-reihe { display: flex; gap: .8rem; flex-wrap: wrap; margin-top: 1.5rem; }

/* ---------- Hero ---------- */
.hero { padding-top: clamp(2.5rem, 6vw, 5rem); }
.hero .container { display: grid; grid-template-columns: 1.05fr 1fr; gap: 3rem; align-items: center; }
.hero h1 { margin-bottom: .6em; }
.hero .lead { font-size: 1.25rem; line-height: 1.5; color: var(--tinte); }
.hero-bild { position: relative; }
.hero-bild img { border-radius: 8px; box-shadow: 0 30px 60px -30px rgba(34,48,60,.45); }
.hero-bild figcaption { margin-top: .6rem; font-size: .9rem; color: var(--tinte-leicht); }
@media (max-width: 860px) { .hero .container { grid-template-columns: 1fr; } }

/* ---------- Ablauf (drei Schritte, echte Reihenfolge) ---------- */
.schritte { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; margin-top: 2.5rem; counter-reset: schritt; }
.schritte > div { padding-top: 1rem; border-top: 2px solid var(--gold); }
.schritte > div::before {
  counter-increment: schritt; content: counter(schritt) ".";
  font-family: var(--serif); font-size: 2.2rem; color: var(--gold); display: block; line-height: 1;
  margin-bottom: .4rem;
}
.schritte h3 { margin-bottom: .3em; }
@media (max-width: 720px) { .schritte { grid-template-columns: 1fr; } }

/* ---------- Funktionen (Liste, keine Kacheln) ---------- */
.funktionen { display: grid; grid-template-columns: 1fr 1fr; gap: 1.8rem 3rem; margin-top: 2rem; }
.funktionen > div { display: grid; grid-template-columns: 2.6rem 1fr; gap: .8rem; align-items: start; }
.funktionen svg { width: 2rem; height: 2rem; stroke: var(--gruen); fill: none; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; margin-top: .2rem; }
.funktionen h3 { font-size: 1.3rem; margin-bottom: .2em; }
.funktionen p { margin: 0; font-size: 1rem; }
@media (max-width: 720px) { .funktionen { grid-template-columns: 1fr; } }

/* ---------- Screenshots ---------- */
.galerie { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 1.4rem; margin-top: 2rem; }
.galerie figure { margin: 0; }
.galerie img { border-radius: 14px; border: 1px solid var(--linie); background: #fff; }
.galerie figcaption { margin-top: .5rem; font-size: .9rem; color: var(--tinte-leicht); text-align: center; }

.tv-foto { display: grid; grid-template-columns: 1.4fr 1fr; gap: 2rem; align-items: center; margin-top: 2.5rem; }
.tv-foto img { border-radius: 8px; }
@media (max-width: 720px) { .tv-foto { grid-template-columns: 1fr; } }

/* ---------- Tabelle ---------- */
table { width: 100%; border-collapse: collapse; margin: 1.5rem 0; font-size: .98rem; background: var(--papier); }
th, td { text-align: left; padding: .7rem .9rem; border-bottom: 1px solid var(--linie); vertical-align: top; }
th { font-weight: 600; background: #efede6; }
td:last-child, th:last-child { white-space: nowrap; }

/* ---------- Kontakt ---------- */
.kontakt { background: var(--papier); }
.kontakt .container { display: grid; grid-template-columns: 1.2fr 1fr; gap: 3rem; }
.kontakt address { font-style: normal; font-size: 1.15rem; line-height: 1.8; }
@media (max-width: 720px) { .kontakt .container { grid-template-columns: 1fr; } }

/* ---------- Fuß ---------- */
footer { padding: 2rem 0 2.5rem; border-top: 1px solid var(--linie); font-size: .92rem; color: var(--tinte-leicht); }
footer .container { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
footer a { color: var(--tinte-leicht); }

/* ---------- Rechtstexte ---------- */
.rechtstext { padding-top: 3rem; }
.rechtstext .container { max-width: 760px; }
.rechtstext h2 { font-size: 1.6rem; margin-top: 2.2rem; }
.rechtstext h3 { font-size: 1.2rem; margin-top: 1.4rem; }
.platzhalter { background: #fff6d6; border: 1px dashed var(--gold); padding: .05em .35em; border-radius: 3px; }
.hinweis-box { background: #fff6d6; border-left: 4px solid var(--gold); padding: 1rem 1.2rem; margin: 1.5rem 0; }

/* ============================================================
   DEMO
   ============================================================ */
.demo { background: #eceae3; }
.demo-buehne {
  display: grid; grid-template-columns: 360px 1fr; gap: 2.5rem; align-items: start; margin-top: 2.5rem;
}
@media (max-width: 900px) {
  .demo-buehne { grid-template-columns: 1fr; }
  /* Am Handy: Fernseher oben festhalten, damit die Reaktion sichtbar bleibt */
  .tv-wrap { order: -1; position: sticky; top: 64px; z-index: 10; background: #eceae3; padding: .5rem 0 .6rem; }
  .tv-rahmen { padding: 5px; border-radius: 6px; }
  .tv-status { margin-top: .4rem; font-size: .85rem; }
}

/* Handy */
.handy {
  width: 360px; max-width: 100%; margin-inline: auto;
  background: #0b1020; border-radius: 34px; padding: 12px;
  box-shadow: 0 25px 50px -20px rgba(0,0,0,.55), inset 0 0 0 2px #2b3350;
  color: #fff; font-family: Arial, Helvetica, sans-serif;
}
.handy-screen { background: var(--app-bg); border-radius: 24px; overflow: hidden; min-height: 620px; display: flex; flex-direction: column; }
.app-kopf { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px 6px; font-size: 13px; color: #cfd6e6; }
.app-kopf .signal { display: inline-flex; align-items: flex-end; gap: 2px; height: 14px; margin-right: 8px; }
.app-kopf .signal i { width: 3px; background: var(--app-gruen); display: block; }
.app-kopf .ok { display: inline-block; width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--app-gruen); color: var(--app-gruen); font-size: 11px; line-height: 14px; text-align: center; }
.app-titel { padding: 0 16px; font-size: 13px; color: #9aa6c0; }
.app-tabs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; padding: 10px 12px; }
.app-tabs button {
  background: var(--app-panel); border: 2px solid transparent; color: #fff; border-radius: 12px;
  padding: 10px 4px 8px; font: 12px Arial, sans-serif; cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 4px;
}
.app-tabs button span:first-child { font-size: 20px; }
.app-tabs button[aria-selected="true"] { border-color: var(--app-gruen); color: var(--app-gruen); }
.app-tabs button[data-tab="text"][aria-selected="true"] { border-color: var(--app-orange); color: var(--app-orange); }
.app-tabs button[data-tab="bilder"][aria-selected="true"] { border-color: #6fb2ff; color: #6fb2ff; }
.app-inhalt { padding: 6px 12px 14px; flex: 1; }
.app-inhalt [hidden] { display: none !important; }

.lied-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.lied-grid input {
  width: 100%; background: var(--app-bg2); border: 1px solid #2f4a7a; border-radius: 8px;
  color: #fff; font: 700 18px Arial, sans-serif; text-align: center; padding: 9px 4px;
}
.lied-grid input::placeholder { color: #4b5f85; font-weight: 400; }
.app-btn {
  display: block; width: 100%; margin-top: 10px; border: none; border-radius: 10px; padding: 11px;
  font: 700 15px Arial, sans-serif; cursor: pointer; color: #fff; background: var(--app-panel);
}
.app-btn.gruen { background: var(--app-gruen2); color: #08281a; }
.app-btn.rot { background: #7a1f1f; }
.app-btn.orange { background: var(--app-orange); color: #2a1a00; }
.app-btn.blau { background: #2e5aa8; }
.app-btn.grau { background: #3a4460; }
.app-vorschau {
  margin-top: 12px; background: #0a1f12; border-radius: 10px; padding: 12px; text-align: center;
  color: var(--app-gruen); font: 700 34px Arial, sans-serif; min-height: 64px;
}
.app-vorschau small { display: block; color: #6ea88a; font-size: 12px; font-weight: 400; }
.app-titel-zeile { margin-top: 6px; font-size: 12px; color: #9aa6c0; text-align: center; min-height: 1.4em; }

.pfeile { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 10px; }
.pfeile .app-btn { margin-top: 0; font-size: 22px; }
.live-liste { margin: 12px 0 0; padding: 10px 12px; list-style: none; background: #0f1f3d; border-radius: 10px; font: 15px Arial, sans-serif; }
.live-liste li { display: flex; gap: 10px; padding: 2px 0; color: #dfe6f5; }
.live-liste li span:first-child { color: #6b7ea3; width: 1.4em; }
.live-liste li.aktiv { color: var(--app-gruen); font-weight: 700; }

.app-inhalt textarea {
  width: 100%; min-height: 76px; background: var(--app-bg2); border: 1px solid #2f4a7a; border-radius: 8px;
  color: #fff; font: 15px Arial, sans-serif; padding: 8px; resize: vertical;
}
.regler { display: flex; align-items: center; gap: 10px; font-size: 12px; color: #9aa6c0; margin-top: 8px; }
.regler input { flex: 1; accent-color: var(--app-gruen); }
.text-block { border-bottom: 1px solid #2b3a5e; padding-bottom: 12px; margin-bottom: 12px; }
.text-block:last-child { border: none; }

.bild-kacheln { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 6px; }
.bild-kacheln button { padding: 0; border: 2px solid transparent; border-radius: 8px; overflow: hidden; background: #000; cursor: pointer; }
.bild-kacheln button[aria-pressed="true"] { border-color: #6fb2ff; }
.bild-kacheln img { aspect-ratio: 16/9; object-fit: cover; }
.app-hinweis { font-size: 12px; color: #9aa6c0; margin: 8px 0 0; }

/* Fernbedienung */
.fernbedienung { margin: 1.4rem auto 0; width: 150px; background: #f4f4f2; border-radius: 22px; padding: 14px; box-shadow: 0 12px 24px -12px rgba(0,0,0,.4), inset 0 0 0 1px #d8d8d4; }
.fernbedienung p { margin: 0 0 8px; text-align: center; font-size: .78rem; color: var(--tinte-leicht); }
.fernbedienung .tasten { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.fernbedienung button { aspect-ratio: 1; border-radius: 12px; border: 1px solid #c9c9c4; background: #fff; font: 700 22px var(--sans); color: var(--tinte); cursor: pointer; }
.fernbedienung button:active { background: #e6e6e2; }
.fernbedienung button svg { width: 22px; height: 22px; stroke: var(--tinte); fill: none; stroke-width: 2.2; }
.fernbedienung button.gefuellt svg { fill: var(--tinte); }

/* Fernseher */
.tv-wrap { position: sticky; top: 84px; }
.tv-rahmen { background: #111; border-radius: 10px; padding: 10px; box-shadow: 0 30px 60px -25px rgba(0,0,0,.6); }
.tv {
  position: relative; aspect-ratio: 16/9; background: #000; overflow: hidden;
  font-family: Arial, Helvetica, sans-serif; color: #fff;
  container-type: inline-size;
}
.tv > div { position: absolute; inset: 0; display: none; }
.tv > div.aktiv { display: flex; }

.tv-lieder { display: flex; }
.tv-lieder.aktiv { display: grid; grid-template-columns: 1fr 1fr; }
.tv-haupt { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 4cqw; text-align: center; }
.tv-haupt .zaehler { color: #7d8a9e; font-size: 2.2cqw; letter-spacing: .18em; }
.tv-haupt .nummer { color: var(--app-gruen); font: 900 17cqw/1 "Arial Black", Arial, sans-serif; text-shadow: 0 0 2cqw rgba(0,255,136,.35); }
.tv-haupt .titel { font-size: 2.6cqw; font-weight: 700; margin-top: 1.2cqw; max-width: 90%; }
.tv-liste { display: flex; flex-direction: column; justify-content: center; align-items: flex-end; gap: 3.2cqw; padding: 3cqw 6cqw; }
.tv-liste div { font: 900 7.5cqw/1 "Arial Black", Arial, sans-serif; color: #fff; }

.tv-text { align-items: center; justify-content: center; text-align: center; padding: 6cqw; font-weight: 700; line-height: 1.3; white-space: pre-wrap; }
.tv-bild { }
.tv-bild img { width: 100%; height: 100%; object-fit: contain; }
.tv-schwarz { background: #000; }
.tv-standby { background: #000; align-items: center; justify-content: center; color: #333; font-size: 2.5cqw; }

.tv-status { margin-top: .8rem; font-size: .92rem; color: var(--tinte-leicht); }
.tv-status b { color: var(--tinte); font-weight: 600; }

/* Kontaktdaten als Bild (Spam-Schutz) */
.kontakt-bild { height: 1.6em; width: auto; margin: .25em 0 .4em; }
