/* Poloha uživatele na řece (fáze 5, krok 5.7 – docs/PLAN-FAZE-5-PWA.md): loď v seznamu míst, hláška nad seznamem, úsek
   v přehledu, loď v mapě a ovládání „Moje poloha“. Provizorní vzhled ve stávajícím vizuálním systému (P1) – konečný
   design s obrazovkami aplikace (krok 5.9). Načítá se na stránce řeky a místa (ne ve widgetu frame.aspx). */

/* ---------- loď v seznamu (stará Android aplikace: ikona lodi mezi místy) ---------- */
.ax-boat { display: grid; grid-template-columns: var(--km-col) 44px minmax(0, 1fr); min-height: 52px; list-style: none; }
.ax-boat .pt-km b { color: #1565c0; }
.ax-boat .ax-line { position: relative; display: flex; align-items: center; justify-content: center; }
.ax-boat-node {
  position: relative; z-index: 2; display: flex; align-items: center; justify-content: center; width: 36px; height: 36px;
  border-radius: 50%; background: #1e88e5; color: #fff; box-shadow: 0 0 0 4px rgba(30, 136, 229, .25), 0 2px 6px rgba(0, 0, 0, .25);
}
.ax-boat-text { display: flex; flex-direction: column; justify-content: center; gap: 2px; padding-left: 6px; }
.ax-boat-text strong { font-size: 17px; font-weight: 700; color: #1565c0; }
.ax-boat-text small { font-size: 13px; color: var(--c-muted); }
.ax-boat.is-approx .ax-boat-node { background: #90caf9; box-shadow: 0 0 0 4px rgba(144, 202, 249, .35); }

/* hláška nad seznamem: hledá se poloha, odmítnuto, daleko od řeky */
.ax-note {
  display: flex; align-items: center; gap: 10px; margin: 8px 8px 12px; padding: 10px 14px; list-style: none;
  border-radius: var(--r-m); background: #e3f2fd; color: #0d3c61; font-size: 14px; line-height: 1.4;
}
.ax-note svg { flex: none; color: #1565c0; }

/* přehled řeky: úsek, ve kterém uživatel je */
.ov-position {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin-top: 14px; padding: 10px 14px;
  border-radius: var(--r-m); background: #e3f2fd; color: #0d3c61; font-size: 15px;
}
.ov-position svg { color: #1565c0; }

/* loď v mapě – místo na ose řeky, kam se poloha promítla */
.map-boat .mk {
  display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 50%;
  background: #1e88e5; color: #fff; border: 2px solid #fff; box-shadow: 0 2px 8px rgba(0, 0, 0, .3);
}

/* ---------- ovládání „Moje poloha“ (Android: velké tlačítko vpravo dole) ---------- */
.ra-pos {
  grid-area: axis; align-self: end; justify-self: end; z-index: 800; margin: 0 16px 16px 0;
  display: flex; flex-direction: column; align-items: flex-end; gap: 8px; pointer-events: none;
}
.ra-pos > * { pointer-events: auto; }
.ra-pos-main {
  display: inline-flex; align-items: center; gap: 8px; height: 48px; padding: 0 18px 0 14px; border: 0; border-radius: var(--r-pill);
  background: var(--c-primary); color: #fff; font: inherit; font-size: 15px; font-weight: 500; cursor: pointer;
  box-shadow: 0 4px 16px rgba(0, 0, 0, .25);
}
.ra-pos-main:hover { background: var(--c-primary-hover); }
.ra-pos[data-pos-state="on"] .ra-pos-main, .ra-pos[data-pos-state="waiting"] .ra-pos-main { background: #1e88e5; }
.ra-pos-more {
  display: none; flex-direction: column; align-items: stretch; gap: 2px; padding: 6px; border-radius: var(--r-m);
  background: #fff; box-shadow: 0 4px 16px rgba(0, 0, 0, .22); font-size: 14px;
}
.ra-pos.is-open:not([data-pos-state="off"]) .ra-pos-more { display: flex; } /* otevře klepnutí na tlačítko polohy */
.ra-pos-more button, .ra-pos-more label {
  display: flex; align-items: center; gap: 8px; min-height: 36px; padding: 0 10px; border: 0; border-radius: var(--r-s);
  background: none; color: var(--c-text); font: inherit; text-align: left; cursor: pointer;
}
.ra-pos-more button:hover, .ra-pos-more label:hover { background: var(--c-list); }
.ra-pos-more input { margin: 0; }

@media (max-width: 1279.98px) {
  .ra-pos { grid-area: view; }
  .river-app[data-view="map"] .ra-pos { margin-bottom: 40px; } /* nad atribucí mapy */
}

@media (max-width: 767.98px) {
  .ra-pos { margin: 0 12px 84px 0; } /* nad přepínačem Seznam | Mapa */
  .river-app.has-detail .ra-pos { display: none; }
  .ra-pos-main { height: 44px; padding: 0 14px 0 12px; }
}

@media print {
  .ra-pos, .ax-note { display: none; }
}
