/* Anwendungen v13 (29.09. abends). Nur fuer diese Seite (main.anw), baut auf css/unterseiten.css auf.
   Seitenkopf einspaltig auf schmalen Bildschirmen, Einsatzprofile als Scroll-Geschichte, Standort-Empfehler (js/site.js schaltet
   die Tafeln ueber hidden um), Geraete als Baukasten: der Automat ist immer dabei, Kaffee, Eis und Pizza kommen dazu. */

/* ---------- Seitenkopf ---------- */
.anw .kopf13 .bild > img { object-position: 80% 50%; }
/* Oeffnen des Bildes: jetzt in unterseiten.css am Bild selbst, die Plakette bleibt ganz. */
@media (max-width: 900px) {
  .anw .kopf13 .raster { grid-template-columns: minmax(0, 1fr); gap: 44px; }   /* fehlt in unterseiten.css: Bild unter den Text */
  .anw .kopf13 .bild > img { aspect-ratio: 5 / 4; }
  .anw .kopf13 .plakette { left: 14px; bottom: 16px; }
}
@media (max-width: 640px) {
  .anw .kopf13 .fakten { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
  .anw .kopf13 .fakten div { min-width: 0; }
  .anw .kopf13 .fakten b { font-size: 34px; }
  .anw .kopf13 .fakten span { font-size: 11px; letter-spacing: .03em; }
  .anw .kopf13 .aktionen .knopf { flex: 1 1 auto; justify-content: center; }
  .anw .kopf13 .plakette { left: 12px; bottom: 12px; right: 12px; max-width: none; padding: 10px 14px 10px 10px; gap: 10px; border-radius: 20px; }
  .anw .kopf13 .plakette i { width: 38px; height: 38px; }
  .anw .kopf13 .plakette b { font-size: 14px; }
  .anw .kopf13 .plakette span { font-size: 12.5px; }
}

/* ---------- Einsatzprofile (Scroll-Geschichte) ---------- */
.anw .story13 li > .nr, .anw .story13 li > .tag, .anw .story13 li > .mehr { align-self: flex-start; }
.anw .story13 .buehne13 img[src*="foto-hub-abend"] { object-position: 84% 50%; }
.anw .story13 .buehne13 img[src*="foto-laden"] { object-position: 10% 50%; }
.anw .story13 .buehne13 img[src*="foto-cafeteria"] { object-position: 30% 50%; }

/* ---------- Haken-Liste (Empfehler, Geraete) ---------- */
.anw ul.haken { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.anw ul.haken li { position: relative; padding-left: 30px; font-size: 16px; line-height: 1.45; color: var(--ink); }
.anw ul.haken li::before { content: ""; position: absolute; left: 0; top: .2em; width: 18px; height: 18px; border-radius: 50%; background: var(--green-tint);
                            box-shadow: inset 0 0 0 5px var(--green); }
.anw ul.haken a { color: var(--green-2); font-weight: 700; }

/* ---------- Standort-Empfehler ---------- */
body.u13 .anw #empfehler .kopfzeile { max-width: 66em; }   /* zwei Saetze, zwei Zeilen */
.anw .empfehler .filter { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 20px; }
.anw .empfehler .filter button { font: 600 15px/1.2 var(--font-body); padding: 13px 20px; border-radius: var(--pill); background: #fff; border: 1px solid var(--line);
                                 color: var(--ink); transition: background-color .3s, color .3s, border-color .3s, box-shadow .3s, transform .3s var(--ease-in-out); }
.anw .empfehler .filter button:hover { border-color: var(--green-light); transform: translateY(-1px); }
.anw .empfehler .filter button.aktiv { background: var(--green-2); border-color: var(--green-2); color: #fff; box-shadow: 0 16px 30px -18px rgba(42,137,67,.9); transform: none; }

.anw .empfehler-tafel:not([hidden]) { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(28px, 4vw, 56px); align-items: center;
                                      background: #fff; border: 1px solid var(--line); border-radius: 44px; padding: clamp(26px, 3.4vw, 48px);
                                      box-shadow: 0 50px 90px -70px rgba(15,51,25,.55); animation: tafel13 .6s var(--ease-in-out) both; }
.anw .tafel-text h3 { font-size: clamp(28px, 2.5vw, 38px); line-height: 1.06; margin: 0 0 20px; }
.anw .tafel-text .aktionen { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.anw .tafel-text .aktionen .knopf { padding: 13px 20px; font-size: 15px; }

.anw .tafel-geraete { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 14px; }
.anw .gk { display: flex; flex-direction: column; text-decoration: none; color: inherit; background: var(--paper); border: 1px solid var(--line); border-radius: 28px;
           overflow: hidden; transition: transform .4s var(--ease-in-out), box-shadow .4s; animation: tafel13 .6s var(--ease-in-out) both; }
.anw .gk:nth-child(2) { animation-delay: 70ms; } .anw .gk:nth-child(3) { animation-delay: 140ms; }
.anw .gk:hover { transform: translateY(-4px); box-shadow: 0 30px 50px -36px rgba(15,51,25,.55); }
.anw .gk-bild { display: block; height: 210px; padding: 18px 18px 0; background: linear-gradient(180deg, #ffffff 0%, #e9f4ec 100%); }
.anw .gk-bild img { display: block; width: 100%; height: 100%; object-fit: contain; object-position: 50% 100%; transition: transform .8s var(--ease-in-out); }
.anw .gk:hover .gk-bild img { transform: translateY(-4px); }
.anw .gk.foto .gk-bild { padding: 0; }
.anw .gk.foto .gk-bild img { object-fit: cover; object-position: 50% 50%; }
.anw .gk b { display: block; font-size: 16.5px; line-height: 1.25; padding: 16px 18px 0; }
.anw .gk > span:last-child { display: block; font-size: 14.5px; line-height: 1.4; color: var(--muted); padding: 5px 18px 18px; }
@keyframes tafel13 { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
.anw .emp-hinweis { display: flex; align-items: center; gap: 12px; margin-top: 22px; padding-left: clamp(4px, 1vw, 12px); font-size: 15.5px; color: var(--muted); }
.anw .emp-hinweis::before { content: ""; flex: none; width: 26px; height: 2px; border-radius: 2px; background: var(--green); }

/* ---------- Geraete als Baukasten ---------- */
.anw .baukasten { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px; }
.anw .bk-haupt, .anw .bk-karte { text-decoration: none; color: inherit; background: #fff; border: 1px solid var(--line); overflow: hidden; display: grid;
                                 transition: transform .45s var(--ease-in-out), box-shadow .45s; }
.anw .bk-haupt:hover, .anw .bk-karte:hover { transform: translateY(-5px); box-shadow: 0 40px 70px -50px rgba(15,51,25,.55); }
/* Bilder liegen absolut in ihrer Spalte: die Kartenhoehe richtet sich nach dem Text, nicht nach dem Hochformat der Geraete */
.anw .bk-bild { position: relative; display: block; overflow: hidden; margin: 10px 0 10px 10px; border-radius: 38px; background: linear-gradient(180deg, #f6fbf7 0%, #e3f2e7 100%); }
.anw .bk-bild::after { content: ""; position: absolute; left: 14%; right: 14%; bottom: 4px; height: 18px; border-radius: 50%;
                       background: radial-gradient(closest-side, rgba(15,51,25,.16), rgba(15,51,25,0)); }
.anw .bk-bild img { position: absolute; inset: 0; z-index: 1; display: block; width: 100%; height: 100%; object-fit: contain; object-position: 50% 100%;
                    transition: transform 1s var(--ease-in-out); }
.anw .bk-haupt:hover .bk-bild img, .anw .bk-karte:hover .bk-bild img { transform: translateY(-5px); }
.anw .bk-text { display: flex; flex-direction: column; justify-content: center; align-items: flex-start; }
.anw .bk-text .tag { display: inline-block; font-size: 12.5px; font-weight: 700; color: var(--green-2); background: var(--green-tint); border-radius: var(--pill); padding: 6px 12px; }
.anw .bk-text .pfeil { display: inline-block; margin-top: 16px; font-weight: 700; color: var(--green-2); }

.anw .bk-haupt { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); border-radius: 48px; }
.anw .bk-haupt .bk-bild img { padding: 70px 26px 14px; }
.anw .bk-haupt .marke { position: absolute; left: 22px; top: 22px; z-index: 2; background: var(--green); color: #fff; font-weight: 700; font-size: 13px; letter-spacing: .04em;
                        border-radius: var(--pill); padding: 8px 14px; }
.anw .bk-haupt .bk-text { padding: 40px 34px 40px 30px; }
.anw .bk-haupt h3 { font-size: clamp(32px, 3vw, 46px); margin: 16px 0 18px; }
.anw .bk-zahl { display: flex; flex-direction: column; gap: 6px; margin: 0 0 18px; padding-bottom: 18px; border-bottom: 1px solid var(--line); width: 100%; }
.anw .bk-zahl b { font: 800 clamp(44px, 4.2vw, 64px)/1 var(--font-display); color: var(--green-2); letter-spacing: -.01em; }
.anw .bk-zahl span { font-size: 15px; line-height: 1.35; color: var(--muted); }

.anw .bk-dazu { display: grid; grid-template-rows: repeat(3, minmax(0, 1fr)); gap: 18px; }
.anw .bk-karte { grid-template-columns: 168px minmax(0, 1fr); border-radius: 36px; }
.anw .bk-karte .bk-bild { border-radius: 28px; }
.anw .bk-karte .bk-bild img { padding: 16px 16px 10px; }
.anw .bk-karte .bk-text { padding: 24px 28px 24px 24px; }
.anw .bk-karte h3 { font-size: clamp(22px, 1.9vw, 27px); margin: 10px 0 6px; }
.anw .bk-karte p { font-size: 15px; line-height: 1.45; color: var(--muted); }
.anw .bk-karte .pfeil { margin-top: 10px; font-size: 15px; }

.anw .schluss13 { margin-top: 18px; background: var(--paper); }
.anw .schluss13 > div:first-child { flex: 1 1 26em; }
.anw .schluss13 p { margin-top: 8px; color: var(--muted); font-size: 15.5px; max-width: 40em; }
.anw .schluss13 .aktionen { display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------- mittlere und schmale Bildschirme ---------- */
@media (max-width: 1100px) {
  /* einspaltige Tafel: erst Aussage und Punkte, dann die Geraete, dann die Knoepfe */
  .anw .empfehler-tafel:not([hidden]) { grid-template-columns: minmax(0, 1fr); gap: 22px; }
  .anw .tafel-text { display: contents; }
  .anw .tafel-text h3 { margin: 0; }
  .anw .tafel-geraete { order: 1; }
  .anw .tafel-text .aktionen { order: 2; margin-top: 2px; }
  .anw .baukasten { grid-template-columns: minmax(0, 1fr); }
  .anw .bk-haupt { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); }
  .anw .bk-haupt .bk-bild { min-height: 440px; }
}
@media (max-width: 640px) {
  .anw .empfehler .filter { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; }
  .anw .empfehler .filter button { border-radius: 18px; padding: 12px 14px; font-size: 14.5px; text-align: left; }
  .anw .empfehler-tafel:not([hidden]) { border-radius: 32px; padding: 24px 20px; gap: 24px; }
  .anw .tafel-text h3 { font-size: 27px; }
  .anw .tafel-text .aktionen .knopf { width: 100%; justify-content: center; }
  .anw .tafel-geraete { grid-auto-flow: row; grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .anw .gk { display: grid; grid-template-columns: 84px minmax(0, 1fr); grid-template-rows: auto auto; column-gap: 14px; align-items: center; border-radius: 22px; }
  .anw .gk-bild { grid-row: 1 / 3; height: 104px; padding: 10px 8px 0; }
  .anw .gk b { padding: 14px 14px 0 0; align-self: end; }
  .anw .gk > span:last-child { padding: 3px 14px 14px 0; align-self: start; }
  .anw .bk-haupt { grid-template-columns: minmax(0, 1fr); border-radius: 36px; }
  .anw .bk-haupt .bk-bild { min-height: 0; height: 360px; margin: 10px 10px 0; border-radius: 28px; }
  .anw .bk-haupt .bk-bild img { padding: 62px 20px 12px; }
  .anw .bk-haupt .bk-text { padding: 26px 24px 30px; }
  .anw .bk-karte { grid-template-columns: 120px minmax(0, 1fr); border-radius: 30px; }
  .anw .bk-karte .bk-bild { margin: 8px 0 8px 8px; border-radius: 22px; }
  .anw .bk-karte .bk-bild::after { display: none; }
  .anw .bk-karte .bk-bild img { padding: 10px 6px; object-position: 50% 50%; }
  .anw .bk-karte .bk-text { padding: 20px 20px 20px 16px; }
  .anw .schluss13 { border-radius: 32px; padding: 24px 22px; }
  .anw .schluss13 .aktionen .knopf { flex: 1 1 auto; justify-content: center; }
}

/* Bewegung reduzieren */
@media (prefers-reduced-motion: reduce) {
  .anw .kopf13 .bild.auf, .anw .empfehler-tafel:not([hidden]), .anw .gk { animation: none; }
}
