/* Wspólny wygląd aplikacji przewodnika (Guide/Index, Guide/Paths, Guide/Path). */
:root {
    --g-bg: #f4f6fa;
    --g-surface: #ffffff;
    --g-ink: #0f172a;
    --g-ink-2: #334155;
    --g-muted: #64748b;
    --g-line: #e6e9f0;
    --g-accent: #2f6bff;
    --g-accent-hover: #1f58e6;
    --g-accent-soft: #eaf0ff;
    --g-danger: #dc2626;
    --g-danger-soft: #fdecec;
    --g-warn-soft: #fff6e5;
    --g-radius: 16px;
    --g-radius-sm: 12px;
    --g-shadow: 0 1px 2px rgba(15, 23, 42, .05), 0 6px 18px rgba(15, 23, 42, .06);
    --g-shadow-lg: 0 12px 32px rgba(15, 23, 42, .16);
    --g-nav-h: 64px;
    --g-font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

body.g-app {
    background: var(--g-bg) !important;
    color: var(--g-ink);
    font-family: var(--g-font);
    -webkit-font-smoothing: antialiased;
}

.g-app h1, .g-app h2, .g-app h3, .g-app h4, .g-app h5 {
    font-family: var(--g-font);
    color: var(--g-ink);
    letter-spacing: -.01em;
}

.g-icon { width: 20px; height: 20px; flex-shrink: 0; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.g-icon--fill { fill: currentColor; stroke: none; }

/* ---------- Pasek aplikacji ---------- */
.g-appbar {
    position: sticky;
    top: 0;
    z-index: 1010;
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 56px;
    padding: 8px 56px 8px 16px;
    background: rgba(244, 246, 250, .88);
    backdrop-filter: saturate(180%) blur(12px);
    -webkit-backdrop-filter: saturate(180%) blur(12px);
}
.g-appbar__brand { font-weight: 800; font-size: 20px; letter-spacing: -.02em; color: var(--g-ink); text-decoration: none !important; }
.g-appbar__brand span { color: var(--g-accent); }
.g-appbar__title { font-weight: 700; font-size: 17px; margin: 0; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.g-appbar__back {
    display: inline-flex; align-items: center; justify-content: center;
    width: 38px; height: 38px; margin-left: -6px; border-radius: 50%;
    color: var(--g-ink); text-decoration: none !important;
}
.g-appbar__back:hover { background: rgba(15, 23, 42, .06); color: var(--g-ink); }
.g-appbar__chip { margin-left: auto; font-size: 13px; font-weight: 600; color: var(--g-muted); background: var(--g-surface); border: 1px solid var(--g-line); border-radius: 999px; padding: 4px 10px; white-space: nowrap; }

/* Przycisk "?" wycieczki po ekranie wpasowany w pasek. */
.g-app .tour-replay { top: 11px !important; right: 12px !important; width: 34px; height: 34px; background: var(--g-surface); color: var(--g-ink-2); box-shadow: none; border: 1px solid var(--g-line); font-size: 15px; }

/* ---------- Dolna nawigacja ---------- */
.g-app .my-navbar.g-nav {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 1030;
    height: calc(var(--g-nav-h) + env(safe-area-inset-bottom, 0px));
    padding: 0 6px env(safe-area-inset-bottom, 0px);
    display: flex; align-items: stretch; justify-content: space-around;
    background: rgba(255, 255, 255, .94);
    backdrop-filter: saturate(180%) blur(12px);
    -webkit-backdrop-filter: saturate(180%) blur(12px);
    border-top: 1px solid var(--g-line);
}
.g-nav .g-nav__item {
    flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
    color: var(--g-muted); text-decoration: none !important; font-size: 11px; font-weight: 600;
    -webkit-tap-highlight-color: transparent; min-width: 0;
}
.g-nav .g-nav__item .g-icon { width: 23px; height: 23px; }
.g-nav .g-nav__item.is-active { color: var(--g-accent); }
@media (hover: hover) { .g-nav .g-nav__item:hover { color: var(--g-ink); } .g-nav .g-nav__item.is-active:hover { color: var(--g-accent); } }

/* ---------- Karty komunikatów (lokalizacja, brak miejsc) ---------- */
.g-notice {
    background: var(--g-surface); border-radius: var(--g-radius); box-shadow: var(--g-shadow);
    padding: 28px 22px 22px; text-align: center; margin: 8px 0 16px;
}
.g-notice__icon {
    width: 64px; height: 64px; margin: 0 auto 16px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: var(--g-accent-soft); color: var(--g-accent);
}
.g-notice__icon .g-icon { width: 30px; height: 30px; }
.g-notice__icon--warn { background: var(--g-warn-soft); color: #b45309; }
.g-notice__title { font-size: 20px; font-weight: 750; margin: 0 0 8px; }
.g-notice__text { font-size: 15px; line-height: 1.5; color: var(--g-muted); margin: 0 0 20px; }

.g-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    min-height: 48px; padding: 12px 20px; border-radius: 14px; border: 0;
    font-weight: 700; font-size: 16px; text-decoration: none !important; cursor: pointer;
    transition: background-color .15s ease, transform .1s ease, box-shadow .15s ease;
}
.g-btn--block { display: flex; width: 100%; }
.g-btn--primary { background: var(--g-accent); color: #fff !important; box-shadow: 0 6px 16px rgba(47, 107, 255, .28); }
.g-btn--primary:hover { background: var(--g-accent-hover); }
.g-btn--primary:active { transform: translateY(1px); }
.g-btn--ghost { background: var(--g-accent-soft); color: var(--g-accent) !important; }
.g-btn--sm { min-height: 36px; padding: 6px 14px; font-size: 14px; border-radius: 10px; }

/* ---------- Lista miejsc ---------- */
.g-section-head { display: flex; align-items: baseline; justify-content: space-between; margin: 4px 2px 10px; }
.g-section-head h2 { font-size: 22px; font-weight: 800; margin: 0; }
.g-section-head span { font-size: 13px; color: var(--g-muted); font-weight: 600; }

.g-app #myContainer.my-container { background: transparent; margin: 0 -6px; }
.g-app .my-place { position: relative; padding: 0 6px 10px; }

.g-place {
    position: relative; display: flex; align-items: center; gap: 14px;
    background: var(--g-surface); border-radius: var(--g-radius); box-shadow: var(--g-shadow);
    padding: 10px 12px 10px 10px; cursor: pointer; height: 100%;
    transition: transform .12s ease, box-shadow .2s ease;
    -webkit-tap-highlight-color: transparent;
}
.g-place:active { transform: scale(.985); }
.g-place__media { position: relative; flex-shrink: 0; }
.g-app .g-place__media img.avatar {
    display: block; width: 84px; height: 84px; margin: 0; border: 0; border-radius: 12px;
    object-fit: cover; background: #e9edf4;
}
.g-place__body { flex: 1; min-width: 0; }
.g-app .g-place__title { margin: 0 0 6px; font-size: 16px; font-weight: 700; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.g-app .g-place__title a { color: var(--g-ink); text-decoration: none; }
.g-place__meta { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 12px; font-size: 13px; color: var(--g-muted); font-weight: 500; }
.g-place__meta .g-icon { width: 15px; height: 15px; }
.g-place__dist { display: inline-flex; align-items: center; gap: 4px; }
.g-place__nav {
    display: inline-flex; align-items: center; gap: 4px; padding: 0; border: 0; background: none;
    color: var(--g-accent); font-weight: 600; font-size: 13px; cursor: pointer;
}
.g-app .g-place .cb-new { font-size: 11px; font-weight: 700; background: #e7f8ef; color: #0f8a4a; border-radius: 6px; padding: 2px 6px; }

.g-play {
    flex-shrink: 0; width: 46px; height: 46px; border-radius: 50%; border: 0; padding: 0;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--g-accent); color: #fff; box-shadow: 0 6px 14px rgba(47, 107, 255, .3);
}
.g-play .g-icon { width: 20px; height: 20px; margin-left: 2px; }

/* Serduszko ulubionych na miniaturze */
.g-app .g-place .fav-toggle {
    position: absolute; top: 4px; left: 4px; right: auto; z-index: 2;
    width: 26px; height: 26px; padding: 0; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: rgba(255, 255, 255, .92); box-shadow: 0 1px 4px rgba(15, 23, 42, .2);
}
.g-app .g-place .fav-toggle .g-icon { width: 15px; height: 15px; color: var(--g-muted); }
.g-app .g-place .fav-toggle.is-fav .g-icon { color: #e0245e; fill: #e0245e; }

/* Miejsce bez opisu — karta widoczna (zdjęcie, nazwa), pod nazwą przycisk przygotowania opowieści */
.g-app .g-place.is-pending { background: #fafbfd; box-shadow: inset 0 0 0 1px var(--g-line); }
.g-place__pending { margin-top: 8px; min-height: 32px; display: flex; align-items: center; }
.g-place__pending .loader { margin: 0; width: 22px; height: 22px; }
.g-pending-btn {
    display: inline-flex; align-items: center; gap: 6px; border: 0; cursor: pointer;
    background: var(--g-accent-soft); color: var(--g-accent); font-weight: 700; font-size: 13px;
    padding: 6px 12px; border-radius: 999px; -webkit-tap-highlight-color: transparent;
}
.g-pending-btn .g-icon { width: 15px; height: 15px; }

/* ---------- Player (pasek nad dolną nawigacją) ---------- */
.g-app .player-modal {
    display: none; position: fixed; left: 0; right: 0; top: auto;
    bottom: calc(var(--g-nav-h) + env(safe-area-inset-bottom, 0px)); z-index: 1040;
    padding: 0 8px 8px; background: transparent;
}
.g-app .player-bar {
    margin: 0 auto; max-width: 720px;
    background: rgba(15, 23, 42, .96); color: #fff;
    border: 0; border-radius: 18px; box-shadow: var(--g-shadow-lg);
    padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 10px;
}
.g-app .player-header { display: flex; align-items: center; gap: 12px; min-width: 0; }
.g-app .player-cover { width: 46px; height: 46px; object-fit: cover; border-radius: 10px; border: 0; background: #1e293b; flex-shrink: 0; }
.g-app .player-meta { flex: 1; min-width: 0; }
.g-app .player-title { font-size: 15px; font-weight: 700; margin: 0; color: #fff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.g-app .player-sub { font-size: 12px; color: rgba(255, 255, 255, .6); margin-top: 1px; }
.g-app .player-controls:empty { display: none; }
.g-app .player-controls .loader { border-color: rgba(255, 255, 255, .2); border-top-color: #fff; }
.g-app .player-controls .alert {
    margin: 0; padding: 10px 12px; border: 0; border-radius: 12px; font-size: 14px;
    background: rgba(255, 255, 255, .1); color: #fff;
}
.g-app .player-controls .alert a { color: #9ec0ff; font-weight: 700; }
.g-app .player-controls .btn-primary { background: var(--g-accent); border: 0; }

.gp { display: flex; flex-direction: column; gap: 8px; }
.gp-buttons { display: flex; align-items: center; justify-content: center; gap: 22px; }
.gp-btn { border: 0; background: none; color: #fff; padding: 0; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.gp-btn--skip { width: 40px; height: 40px; border-radius: 50%; opacity: .85; position: relative; }
.gp-btn--skip .g-icon { width: 26px; height: 26px; }
.gp-btn--skip small { position: absolute; font-size: 9px; font-weight: 800; top: 50%; left: 50%; transform: translate(-50%, -38%); color: #fff; font-family: var(--g-font); }
.gp-btn--play { width: 52px; height: 52px; border-radius: 50%; background: #fff; color: var(--g-ink); }
.gp-btn--play .g-icon { width: 22px; height: 22px; }
.gp-btn--play .gp-ico-play { margin-left: 3px; }
.gp-progress { display: flex; align-items: center; gap: 10px; font-size: 12px; font-variant-numeric: tabular-nums; color: rgba(255, 255, 255, .7); }
.gp-track { position: relative; flex: 1; height: 18px; cursor: pointer; touch-action: none; }
.gp-track::before { content: ""; position: absolute; left: 0; right: 0; top: 7px; height: 4px; border-radius: 4px; background: rgba(255, 255, 255, .2); }
.gp-fill { position: absolute; left: 0; top: 7px; height: 4px; border-radius: 4px; background: #fff; width: 0; }
.gp-fill::after { content: ""; position: absolute; right: -6px; top: -4px; width: 12px; height: 12px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .4); }

/* Odstęp na dole listy, żeby player i nawigacja nie zasłaniały ostatnich kart */
.g-app #listOfPlaces { padding-top: 4px; padding-bottom: 240px; }
.g-app #myContainer::after { content: none; }

/* ---------- Ścieżki ---------- */
.g-search { position: relative; margin: 4px 0 14px; }
.g-search .g-icon { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--g-muted); width: 18px; height: 18px; }
.g-search input {
    width: 100%; height: 48px; border-radius: 14px; border: 1px solid var(--g-line); background: var(--g-surface);
    padding: 0 16px 0 42px; font-size: 16px; color: var(--g-ink); box-shadow: var(--g-shadow); outline: none;
}
.g-search input:focus { border-color: var(--g-accent); box-shadow: 0 0 0 4px var(--g-accent-soft); }
.g-beta { display: flex; gap: 8px; align-items: flex-start; font-size: 13px; line-height: 1.45; color: var(--g-muted); margin: 0 2px 16px; }
.g-beta b { color: var(--g-ink-2); }
.g-beta .g-icon { width: 16px; height: 16px; margin-top: 1px; color: var(--g-muted); }

.g-path-card {
    display: block; height: 100%; overflow: hidden; border-radius: var(--g-radius); background: var(--g-surface);
    box-shadow: var(--g-shadow); color: inherit; text-decoration: none !important; transition: transform .12s ease;
}
.g-path-card:active { transform: scale(.99); }
.g-path-card__media { position: relative; aspect-ratio: 16 / 10; background: #e9edf4; }
.g-path-card__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.g-path-card__media::after { content: ""; position: absolute; inset: 40% 0 0; background: linear-gradient(to bottom, rgba(15, 23, 42, 0), rgba(15, 23, 42, .55)); }
.g-path-card__place { position: absolute; left: 14px; bottom: 12px; z-index: 1; display: inline-flex; align-items: center; gap: 5px; color: #fff; font-size: 13px; font-weight: 600; }
.g-path-card__place .g-icon { width: 15px; height: 15px; }
.g-path-card__body { padding: 14px 16px 16px; }
.g-path-card__title { font-size: 18px; font-weight: 750; margin: 0 0 6px; color: var(--g-ink); }
.g-path-card__desc { font-size: 14px; line-height: 1.5; color: var(--g-muted); margin: 0 0 12px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.g-path-card__foot { display: flex; align-items: center; justify-content: space-between; }
.g-pill { display: inline-flex; align-items: center; gap: 5px; font-size: 13px; font-weight: 600; color: var(--g-ink-2); background: var(--g-bg); border-radius: 999px; padding: 5px 10px; }
.g-pill .g-icon { width: 14px; height: 14px; }
.g-path-card__go { display: inline-flex; align-items: center; gap: 4px; font-size: 14px; font-weight: 700; color: var(--g-accent); }
.g-path-card__go .g-icon { width: 16px; height: 16px; }
.g-empty { text-align: center; color: var(--g-muted); padding: 32px 16px; }

.g-pager { display: flex; justify-content: center; gap: 6px; margin: 8px 0 24px; flex-wrap: wrap; }
.g-pager a, .g-pager span {
    min-width: 40px; height: 40px; padding: 0 10px; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center;
    background: var(--g-surface); color: var(--g-ink-2); font-weight: 600; text-decoration: none !important; box-shadow: var(--g-shadow);
}
.g-pager .is-active { background: var(--g-accent); color: #fff; }
.g-pager .is-disabled { opacity: .4; pointer-events: none; }
.g-page-pad { padding-bottom: calc(var(--g-nav-h) + 24px); }

/* ---------- Ekran ścieżki ---------- */
.g-path-screen { height: 100vh; height: 100dvh; display: flex; flex-direction: column; }
.g-path-screen .g-appbar { position: relative; background: transparent; backdrop-filter: none; -webkit-backdrop-filter: none; }
.g-path-top { padding: 0 16px; }
.g-path-cover { position: relative; border-radius: var(--g-radius); overflow: hidden; background: #e9edf4; aspect-ratio: 16 / 9; max-height: 26vh; width: 100%; }
.g-path-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.g-path-cover .cover-loader { position: absolute; inset: 0; display: none; align-items: center; justify-content: center; background: rgba(255, 255, 255, .5); }
.g-path-cover .cover-loader.active { display: flex; }
.g-path-cover .cover-loader::after { content: ""; width: 30px; height: 30px; border: 3px solid rgba(15, 23, 42, .15); border-top-color: var(--g-accent); border-radius: 50%; animation: spinner-rotate .9s linear infinite; }
.g-path-step { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin: 14px 2px 4px; }
.g-path-step h1 { font-size: 20px; font-weight: 800; line-height: 1.25; margin: 0; }
.g-path-step__count { flex-shrink: 0; font-size: 13px; font-weight: 700; color: var(--g-muted); background: var(--g-surface); border: 1px solid var(--g-line); border-radius: 999px; padding: 4px 10px; font-variant-numeric: tabular-nums; }

.g-path-player { display: flex; flex-direction: column; gap: 6px; margin: 6px 0 12px; }
.g-path-player .gp-progress { color: var(--g-muted); }
.g-path-player .gp-track::before { background: var(--g-line); }
.g-path-player .gp-fill, .g-path-player .gp-fill::after { background: var(--g-accent); }
.g-path-player .gp-buttons { gap: 28px; }
.g-path-player .gp-btn { color: var(--g-ink); }
.g-path-player .gp-btn:disabled { opacity: .35; cursor: default; }
.g-path-player .gp-btn--step .g-icon { width: 28px; height: 28px; }
.g-path-player .gp-btn--play { width: 64px; height: 64px; background: var(--g-accent); color: #fff; box-shadow: 0 8px 20px rgba(47, 107, 255, .35); }
.g-path-player .gp-btn--play .g-icon { width: 26px; height: 26px; }

.g-segment { display: inline-flex; padding: 3px; border-radius: 12px; background: #e8ebf1; }
.g-segment button { border: 0; background: none; padding: 6px 18px; border-radius: 9px; font-size: 14px; font-weight: 650; color: var(--g-muted); cursor: pointer; }
.g-segment button.active { background: var(--g-surface); color: var(--g-ink); box-shadow: 0 1px 3px rgba(15, 23, 42, .12); }

.g-path-panels { flex: 1; min-height: 0; position: relative; margin: 0 16px 16px; }
.g-path-panels .panel { position: absolute; inset: 0; display: none; }
.g-path-panels .panel.active { display: block; }
.g-path-panels #pathMap { width: 100%; height: 100%; border-radius: var(--g-radius); overflow: hidden; }
.g-path-panels #stepsList { height: 100%; overflow: auto; border-radius: var(--g-radius); background: var(--g-surface); box-shadow: var(--g-shadow); }
.g-step-item { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-bottom: 1px solid var(--g-line); cursor: pointer; }
.g-step-item:last-child { border-bottom: 0; }
.g-step-item.active { background: var(--g-accent-soft); }
.g-step-item__num { flex-shrink: 0; width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 800; background: var(--g-bg); color: var(--g-ink-2); }
.g-step-item.active .g-step-item__num { background: var(--g-accent); color: #fff; }
.g-step-item img { width: 52px; height: 52px; object-fit: cover; border-radius: 10px; flex-shrink: 0; background: #e9edf4; }
.g-step-item__title { font-weight: 650; font-size: 15px; line-height: 1.3; }
.g-path-switch { display: flex; justify-content: center; margin: 0 0 10px; }
.disabled-pe { pointer-events: none; opacity: .6; }

@keyframes spinner-rotate { to { transform: rotate(360deg); } }
.g-app .loader { width: 28px; height: 28px; border: 3px solid #e6eef6; border-top-color: var(--g-accent); border-radius: 50%; animation: spinner-rotate .9s linear infinite; margin: 4px auto; }

/* Stare style Index (.play-button, .customMarker) są definiowane w widoku — tu nadpisujemy je z wyższą specyficznością. */
.g-app .g-place .g-play.play-button { width: 44px; height: 44px; margin: 0; font-size: 0; box-shadow: 0 6px 14px rgba(47, 107, 255, .28); background: var(--g-accent); }
.g-app .g-place.is-playing { box-shadow: 0 0 0 2px var(--g-accent), var(--g-shadow); }
.g-app .g-place.is-playing .g-play { background: var(--g-ink); box-shadow: none; }

.g-app .customMarker { width: 40px; height: 40px; margin-left: -20px; margin-top: -48px; padding: 0; border-radius: 50%; background: #fff; box-shadow: 0 3px 10px rgba(15, 23, 42, .3); }
.g-app .customMarker:after { left: 14px; bottom: -6px; border-width: 7px 6px 0; border-color: #fff transparent; }
.g-app .customMarker img { width: 34px; height: 34px; margin: 3px; border-radius: 50%; object-fit: cover; box-shadow: none; }

/* Bez pomarańczowej ramki fokusu przy dotyku; widoczna tylko przy nawigacji klawiaturą. */
.g-app button:focus, .g-app a:focus, .g-app [role="slider"]:focus { outline: none; }
.g-app button:focus-visible, .g-app a:focus-visible { outline: 2px solid var(--g-accent); outline-offset: 2px; }

/* ---------- Mapa ---------- */
/* Google Maps nadpisuje kontenerowi position: relative — bez !important mapa ma zerową wysokość. */
.g-app .g-map { position: fixed !important; left: 0; right: 0; top: 0; bottom: calc(var(--g-nav-h) + env(safe-area-inset-bottom, 0px)); z-index: 1; }
.g-map-locate {
    display: none; position: fixed; right: 12px; z-index: 1020;
    bottom: calc(var(--g-nav-h) + env(safe-area-inset-bottom, 0px) + var(--g-player-h, 0px) + 16px);
    width: 48px; height: 48px; border-radius: 50%; border: 0; background: var(--g-surface); color: var(--g-accent);
    box-shadow: var(--g-shadow-lg); align-items: center; justify-content: center; cursor: pointer;
}
.g-map-open .g-map-locate { display: flex; }
.g-map-open .g-appbar { display: none; }
.g-app .customMarker { width: 34px; height: 34px; margin-left: -17px; margin-top: -42px; }
.g-app .customMarker:after { left: 11px; }
.g-app .customMarker img { width: 28px; height: 28px; }

.g-app .g-navbar-route {
    position: fixed; top: 10px; left: 10px; right: 56px; z-index: 1020;
    align-items: center; gap: 12px; padding: 10px 10px 10px 12px;
    background: var(--g-ink); color: #fff; border-radius: 16px; box-shadow: var(--g-shadow-lg);
}
.g-app .g-navbar-route[style*="block"] { display: flex !important; }
.g-navbar-route__icon { width: 36px; height: 36px; border-radius: 50%; background: var(--g-accent); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.g-navbar-route__icon .g-icon { width: 18px; height: 18px; }
.g-navbar-route__text { flex: 1; min-width: 0; line-height: 1.2; }
.g-navbar-route__text small { display: block; font-size: 12px; color: rgba(255, 255, 255, .65); }
.g-navbar-route__text strong { display: block; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.g-navbar-route__end { border: 0; border-radius: 10px; padding: 8px 12px; background: rgba(255, 255, 255, .14); color: #fff; font-weight: 700; font-size: 14px; flex-shrink: 0; }

/* ---------- Aparat „Rozpoznaj” ---------- */
.g-app .g-camera { position: fixed; inset: 0; z-index: 2000; background: #000; padding: 0 !important; }
.g-camera video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.g-camera__top { position: absolute; top: 0; left: 0; right: 0; display: flex; align-items: center; gap: 10px; padding: calc(12px + env(safe-area-inset-top, 0px)) 14px 12px; background: linear-gradient(rgba(0, 0, 0, .55), rgba(0, 0, 0, 0)); }
.g-camera__close { width: 40px; height: 40px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .18); color: #fff; display: flex; align-items: center; justify-content: center; backdrop-filter: blur(6px); }
.g-app #photoModal .g-camera__beta { position: static; font-size: 12px; font-weight: 600; color: #fff; background: rgba(255, 255, 255, .18); border: 0; border-radius: 999px; padding: 6px 10px; backdrop-filter: blur(6px); }
.g-camera__frame { position: absolute; left: 12%; right: 12%; top: 24%; bottom: 32%; border-radius: 24px; box-shadow: 0 0 0 9999px rgba(0, 0, 0, .25); border: 2px solid rgba(255, 255, 255, .7); pointer-events: none; }
.g-camera__bottom { position: absolute; left: 0; right: 0; bottom: 0; padding: 18px 24px calc(28px + env(safe-area-inset-bottom, 0px)); text-align: center; background: linear-gradient(rgba(0, 0, 0, 0), rgba(0, 0, 0, .65)); }
.g-camera__bottom p { color: #fff; font-size: 15px; line-height: 1.45; margin: 0 0 18px; text-shadow: 0 1px 4px rgba(0, 0, 0, .4); }
.g-camera__shutter { width: 74px; height: 74px; border-radius: 50%; border: 5px solid #fff; background: rgba(255, 255, 255, .25); padding: 0; cursor: pointer; transition: transform .1s ease; }
.g-camera__shutter::after { content: ""; display: block; width: 56px; height: 56px; margin: 4px auto; border-radius: 50%; background: #fff; }
.g-camera__shutter:active { transform: scale(.94); }

/* ---------- Konto ---------- */
.g-account { max-width: 980px; }
.g-profile { display: flex; align-items: center; gap: 14px; background: var(--g-surface); border-radius: var(--g-radius); box-shadow: var(--g-shadow); padding: 16px; margin: 4px 0 14px; }
.g-profile__avatar { width: 52px; height: 52px; border-radius: 50%; flex-shrink: 0; display: flex; align-items: center; justify-content: center; background: var(--g-accent); color: #fff; font-size: 22px; font-weight: 800; }
.g-profile__info { min-width: 0; }
.g-profile__email { font-weight: 700; font-size: 16px; color: var(--g-ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; margin-bottom: 4px; }
.g-status { display: inline-block; font-size: 12px; font-weight: 700; border-radius: 999px; padding: 3px 9px; }
.g-status--ok { background: #e7f8ef; color: #0f8a4a; }
.g-status--off { background: var(--g-danger-soft); color: var(--g-danger); }

.g-account-nav .settings-menu { display: flex; flex-direction: row !important; flex-wrap: nowrap; gap: 8px; overflow-x: auto; margin: 0 -16px 14px; padding: 0 16px 2px; scrollbar-width: none; }
.g-account-nav .settings-menu::-webkit-scrollbar { display: none; }
.g-account-nav .nav-item { flex-shrink: 0; }
.g-account-nav .nav-link, .g-account-nav button.nav-link {
    display: block; white-space: nowrap; padding: 8px 14px !important; border-radius: 999px; border: 1px solid var(--g-line);
    background: var(--g-surface); color: var(--g-ink-2) !important; font-size: 14px !important; font-weight: 600; text-decoration: none !important; margin: 0;
}
.g-account-nav .nav-link.active { background: var(--g-ink); border-color: var(--g-ink); color: #fff !important; }
@media (min-width: 768px) {
    .g-account-nav .settings-menu { flex-direction: column !important; overflow: visible; margin: 0; padding: 8px; background: var(--g-surface); border-radius: var(--g-radius); box-shadow: var(--g-shadow); gap: 2px; }
    .g-account-nav .nav-link, .g-account-nav button.nav-link { border: 0; border-radius: 10px; padding: 10px 12px !important; width: 100%; text-align: left; background: none; }
    .g-account-nav .nav-link.active { background: var(--g-accent-soft); color: var(--g-accent) !important; }
}

.g-account-card { background: var(--g-surface); border-radius: var(--g-radius); box-shadow: var(--g-shadow); padding: 20px 18px; }
.g-account-card h3, .g-account-card h4 { font-size: 20px; font-weight: 800; margin: 0 0 12px; }
.g-account-card label { color: var(--g-ink-2); font-weight: 600; font-size: 14px; }
.g-account-card .form-control { height: 48px; border-radius: 12px; border: 1px solid var(--g-line); font-size: 16px; color: var(--g-ink); }
.g-account-card .form-control:disabled, .g-account-card .form-control[readonly] { background: var(--g-bg); }
.g-account-card .form-control:focus { border-color: var(--g-accent); box-shadow: 0 0 0 4px var(--g-accent-soft); }
.g-account-card .btn { border-radius: 12px; font-weight: 700; padding: 10px 18px; }
.g-account-card .btn-primary { background: var(--g-accent); border: 0; color: #fff !important; box-shadow: 0 6px 16px rgba(47, 107, 255, .25); }
.g-account-card .btn-danger { background: var(--g-danger); border: 0; }
.g-account-card .btn-secondary { background: var(--g-bg); color: var(--g-ink-2); border: 1px solid var(--g-line); }
.g-account-card .alert { border: 0; border-radius: 12px; font-size: 14px; }
.g-account-card .alert-success { background: #e7f8ef; color: #0f6b3a; }
.g-account-card .alert-danger { background: var(--g-danger-soft); color: #9b1c1c; }
.g-account-card .alert-warning { background: var(--g-warn-soft); color: #8a4b08; }
.g-account-card a:not(.btn) { color: var(--g-accent); }
.g-account-card .card { border: 1px solid var(--g-line); border-radius: 14px; overflow: hidden; }
.g-account-card .card-header, .g-account-card .card-footer { background: var(--g-bg); border-color: var(--g-line); }
.g-logout { margin: 14px 0 0; }
.g-logout button { width: 100%; height: 48px; border: 0; border-radius: 14px; background: var(--g-surface); box-shadow: var(--g-shadow); color: var(--g-danger); font-weight: 700; font-size: 15px; }

/* Osiągnięcia */
.g-ach-hero { background: var(--g-ink); color: #fff; border-radius: var(--g-radius); padding: 20px; margin-bottom: 18px; }
.g-ach-hero__label { font-size: 13px; font-weight: 600; color: rgba(255, 255, 255, .7); }
.g-ach-hero__value { font-size: 44px; font-weight: 800; line-height: 1.1; letter-spacing: -.02em; margin: 2px 0 14px; }
.g-ach-hero__bar { height: 8px; border-radius: 8px; background: rgba(255, 255, 255, .15); overflow: hidden; }
.g-ach-hero__bar span { display: block; height: 100%; border-radius: 8px; background: linear-gradient(90deg, #5b8cff, #2f6bff); }
.g-ach-hero__next { font-size: 13px; color: rgba(255, 255, 255, .75); margin-top: 8px; }
.g-account-card .badge-card { border: 1px solid var(--g-line) !important; border-radius: 14px !important; height: 100%; }

/* Powiadomienie o odznace / ulubionych */
.g-app .badge-toast { top: calc(12px + env(safe-area-inset-top, 0px)); background: var(--g-ink); border-radius: 14px; padding: 12px 16px; font-size: 14px; font-weight: 600; box-shadow: var(--g-shadow-lg); }
.g-account-card .form-check { display: flex; align-items: flex-start; gap: 10px; padding-left: 0; }
.g-account-card .form-check-input { position: static; margin: 3px 0 0; width: 18px; height: 18px; flex-shrink: 0; }

/* ---------- Logowanie / rejestracja ---------- */
.g-auth { min-height: 100vh; min-height: 100dvh; display: grid; background: var(--g-surface); }
@media (min-width: 992px) { .g-auth { grid-template-columns: 1fr 1fr; } .g-auth--single { grid-template-columns: 1fr; } }
.g-auth__form { width: 100%; max-width: 420px; margin: 0 auto; padding: 28px 20px 40px; display: flex; flex-direction: column; justify-content: center; }
.g-auth__logo { font-weight: 800; font-size: 24px; letter-spacing: -.02em; color: var(--g-ink) !important; text-decoration: none !important; margin-bottom: 36px; }
.g-auth__logo span { color: var(--g-accent); }
.g-auth__title { font-size: 30px; font-weight: 800; letter-spacing: -.03em; margin: 0 0 8px; }
.g-auth__sub { color: var(--g-muted); font-size: 16px; margin: 0 0 26px; }
.g-auth__error:empty, .g-auth__error.validation-summary-valid { display: none; }
.g-auth__error { background: var(--g-danger-soft); color: #9b1c1c; border-radius: 12px; padding: 10px 14px; font-size: 14px; margin-bottom: 16px; }
.g-auth__error ul { margin: 0; padding-left: 18px; }
.g-field { margin-bottom: 16px; }
.g-field label { display: block; font-size: 14px; font-weight: 600; color: var(--g-ink-2); margin-bottom: 6px; }
.g-field__row { display: flex; justify-content: space-between; align-items: baseline; }
.g-field__row a { font-size: 13px; font-weight: 600; color: var(--g-accent); }
.g-field input { width: 100%; height: 50px; border-radius: 12px; border: 1px solid var(--g-line); background: var(--g-surface); padding: 0 14px; font-size: 16px; color: var(--g-ink); outline: none; transition: border-color .15s ease, box-shadow .15s ease; }
.g-field input:focus { border-color: var(--g-accent); box-shadow: 0 0 0 4px var(--g-accent-soft); }
.g-field input.input-validation-error { border-color: var(--g-danger); }
.g-field__error { display: block; font-size: 13px; color: var(--g-danger); margin-top: 4px; }
.g-check { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--g-ink-2); margin: 4px 0 14px; cursor: pointer; line-height: 1.45; }
.g-check input { width: 18px; height: 18px; margin-top: 1px; flex-shrink: 0; accent-color: var(--g-accent); }
.g-check a { color: var(--g-accent); }
.g-auth .g-btn--primary { margin-top: 6px; height: 52px; }
.g-auth__fine { font-size: 13px; color: var(--g-muted); text-align: center; margin: 12px 0 0; }
.g-auth__switch { text-align: center; color: var(--g-muted); font-size: 15px; margin: 22px 0 0; }
.g-auth__switch a { color: var(--g-accent); font-weight: 700; }
.g-auth__social { display: flex; align-items: center; justify-content: center; width: 100%; height: 50px; border-radius: 12px; border: 1px solid var(--g-line); background: var(--g-surface); font-weight: 700; color: var(--g-ink); margin-bottom: 10px; cursor: pointer; }
.g-auth__or { display: flex; align-items: center; gap: 12px; color: var(--g-muted); font-size: 13px; margin: 6px 0 18px; }
.g-auth__or::before, .g-auth__or::after { content: ""; flex: 1; height: 1px; background: var(--g-line); }
.g-auth__aside { display: none; }
@media (min-width: 992px) {
    .g-auth__aside { display: flex; align-items: center; justify-content: center; background: radial-gradient(700px 400px at 80% 0%, rgba(120, 160, 255, .35), transparent 60%), linear-gradient(150deg, #0f172a, #1e3a8a 65%, #2f6bff); }
}
.g-auth__aside .pm-float--one { left: -150px; top: 300px; }
.g-auth__aside .pm-float--two { right: -110px; }


/* ---------- Zapytaj przewodnika ---------- */
/* Wejście jak pole wyszukiwania; widoczne dopiero po ustaleniu lokalizacji (klasa g-located na body) */
.g-askbar { display: none; align-items: center; gap: 8px; margin: 0 2px 12px; }
.g-located .g-askbar { display: flex; }
.g-askbar__field {
    flex: 1; min-width: 0; display: flex; align-items: center; gap: 10px; height: 48px; padding: 0 16px; cursor: pointer; text-align: left;
    border: 1px solid var(--g-line); border-radius: 999px; background: var(--g-surface); box-shadow: var(--g-shadow);
    color: var(--g-muted); font-family: var(--g-font); font-size: 15px; font-weight: 500; -webkit-tap-highlight-color: transparent;
}
.g-askbar__field .g-icon { width: 20px; height: 20px; color: var(--g-accent); flex-shrink: 0; }
.g-askbar__field span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.g-askbar__mic {
    width: 48px; height: 48px; flex-shrink: 0; border: 0; border-radius: 50%; cursor: pointer;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--g-accent); color: #fff; box-shadow: 0 6px 16px rgba(47, 107, 255, .28); -webkit-tap-highlight-color: transparent;
}
.g-askbar__mic[hidden] { display: none; }
.g-askbar__mic .g-icon { width: 20px; height: 20px; }
/* Na mapie u góry, w miejscu paska nawigacji — chowa się, gdy ten jest widoczny */
.g-askbar--map { position: fixed; top: 10px; left: 10px; right: 56px; margin: 0; z-index: 1020; }
.g-located .g-askbar--map { display: none; }
.g-located.g-map-open .g-askbar--map { display: flex; }
.g-located.g-map-open:has(#navCancel[style*="block"]) .g-askbar--map { display: none; }
.g-askbar--map .g-askbar__field { box-shadow: var(--g-shadow-lg); border-color: transparent; }

.g-ask { position: fixed; inset: 0; z-index: 1100; display: flex; align-items: flex-end; justify-content: center; }
.g-ask[hidden] { display: none; }
.g-ask__backdrop { position: absolute; inset: 0; background: rgba(15, 23, 42, .45); }
.g-ask__panel {
    position: relative; width: 100%; max-width: 720px; max-height: 85vh; max-height: 85dvh; display: flex; flex-direction: column;
    background: var(--g-surface); color: var(--g-ink); border-radius: 22px 22px 0 0; box-shadow: var(--g-shadow-lg);
    padding-bottom: env(safe-area-inset-bottom, 0px); font-family: var(--g-font);
}
.g-ask__head { display: flex; align-items: flex-start; gap: 12px; padding: 18px 16px 10px; border-bottom: 1px solid var(--g-line); }
.g-ask__head > div { flex: 1; min-width: 0; }
.g-ask__title { font-size: 18px; font-weight: 800; letter-spacing: -.01em; margin: 0; }
.g-ask__sub { font-size: 13px; color: var(--g-muted); margin: 2px 0 0; }
.g-ask__quota { font-size: 12px; font-weight: 600; color: var(--g-accent); margin: 4px 0 0; }
.g-ask__quota[hidden] { display: none; }
.g-ask__reset {
    display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 12px; border: 0; border-radius: 999px; cursor: pointer; flex-shrink: 0;
    background: var(--g-bg); color: var(--g-ink-2); font-family: var(--g-font); font-size: 13px; font-weight: 600;
}
.g-ask__reset[hidden] { display: none; }
.g-ask__reset .g-icon { width: 15px; height: 15px; }
.g-ask__close { width: 36px; height: 36px; border: 0; border-radius: 50%; background: var(--g-bg); color: var(--g-ink-2); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; flex-shrink: 0; }
.g-ask__close .g-icon { width: 18px; height: 18px; }
.g-ask__log { flex: 1; min-height: 160px; overflow-y: auto; padding: 14px 16px; display: flex; flex-direction: column; gap: 10px; -webkit-overflow-scrolling: touch; }
.g-ask__hints { display: flex; flex-direction: column; gap: 8px; margin-top: auto; }
.g-ask__hints-label { font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--g-muted); margin: 0 2px; }
.g-ask__hint {
    border: 1px solid var(--g-line); background: var(--g-surface); color: var(--g-ink-2); cursor: pointer;
    border-radius: var(--g-radius-sm); padding: 12px 14px; font-size: 15px; font-weight: 500; text-align: left;
}
.g-ask__msg { max-width: 88%; padding: 10px 14px; border-radius: 18px; font-size: 15px; line-height: 1.45; overflow-wrap: anywhere; }
.g-ask__msg p { margin: 0; }
.g-ask__msg--user { align-self: flex-end; background: var(--g-accent); color: #fff; border-bottom-right-radius: 6px; }
.g-ask__msg--guide { align-self: flex-start; background: var(--g-bg); color: var(--g-ink); border-bottom-left-radius: 6px; }
.g-ask__source { display: block; margin-top: 6px; font-size: 12px; color: var(--g-muted); }
.g-ask__actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.g-ask__action {
    display: inline-flex; align-items: center; gap: 6px; max-width: 100%; height: 32px; padding: 0 12px; border-radius: 999px; cursor: pointer;
    border: 0; background: var(--g-accent-soft); color: var(--g-accent) !important; font-size: 13px; font-weight: 700; text-decoration: none !important;
}
.g-ask__action span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.g-ask__action .g-icon { width: 15px; height: 15px; flex-shrink: 0; }
.g-ask__action--place { background: var(--g-surface); border: 1px solid var(--g-line); color: var(--g-ink-2) !important; }
.g-ask__dots { display: inline-flex; gap: 4px; padding: 4px 0; }
.g-ask__dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--g-muted); animation: g-ask-dot 1.2s infinite ease-in-out; }
.g-ask__dots i:nth-child(2) { animation-delay: .15s; }
.g-ask__dots i:nth-child(3) { animation-delay: .3s; }
@keyframes g-ask-dot { 0%, 80%, 100% { opacity: .25; transform: translateY(0); } 40% { opacity: 1; transform: translateY(-3px); } }
.g-ask__form { display: flex; align-items: center; gap: 8px; padding: 10px 12px 12px; border-top: 1px solid var(--g-line); }
.g-ask__input {
    flex: 1; min-width: 0; height: 44px; padding: 0 16px; border: 1px solid var(--g-line); border-radius: 999px;
    background: var(--g-bg); color: var(--g-ink); font-size: 16px; font-family: var(--g-font); outline: none;
}
.g-ask__input:focus { border-color: var(--g-accent); background: var(--g-surface); }
.g-ask__mic, .g-ask__send {
    width: 44px; height: 44px; flex-shrink: 0; border: 0; border-radius: 50%; cursor: pointer;
    display: inline-flex; align-items: center; justify-content: center; -webkit-tap-highlight-color: transparent;
}
.g-ask__mic { background: var(--g-accent-soft); color: var(--g-accent); }
.g-ask__mic[hidden] { display: none; }
.g-ask__mic.is-listening { background: var(--g-danger); color: #fff; animation: g-ask-pulse 1.4s infinite; }
.g-ask__send { background: var(--g-accent); color: #fff; }
.g-ask__mic .g-icon, .g-ask__send .g-icon { width: 20px; height: 20px; }
@keyframes g-ask-pulse { 0% { box-shadow: 0 0 0 0 rgba(220, 38, 38, .45); } 100% { box-shadow: 0 0 0 14px rgba(220, 38, 38, 0); } }
html.g-ask-open, html.g-ask-open body { overflow: hidden; }
@media (prefers-reduced-motion: reduce) {
    .g-ask__dots i, .g-ask__mic.is-listening { animation: none; }
}


/* ---------- Plan w ustawieniach konta (Manage/Subscription) ---------- */
.g-planbox { margin: 0 0 20px; }
.g-planbox__current { padding: 0 0 14px; }
.g-planbox__label { font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--g-muted); }
.g-planbox__name { font-size: 22px; font-weight: 800; color: var(--g-ink); margin-top: 2px; }
.g-planbox__name span { font-size: 14px; font-weight: 600; color: var(--g-muted); margin-left: 6px; }
.g-planbox__meta { font-size: 14px; color: var(--g-ink-2); margin-top: 2px; }
.g-planbox__upsell {
    border: 1.5px solid var(--g-accent); border-radius: var(--g-radius-sm); padding: 16px;
    background: linear-gradient(180deg, var(--g-accent-soft) 0%, var(--g-surface) 75%);
}
.g-planbox__upsell-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.g-planbox__upsell-head strong { font-size: 18px; font-weight: 800; color: var(--g-ink); }
.g-planbox__tag { font-size: 11px; font-weight: 700; color: #fff; background: var(--g-accent); border-radius: 999px; padding: 2px 9px; white-space: nowrap; }
.g-planbox__list { list-style: none; padding: 0; margin: 0 0 12px; display: grid; gap: 8px; }
.g-planbox__list li { position: relative; padding-left: 24px; font-size: 14px; line-height: 1.4; color: var(--g-ink-2); }
.g-planbox__list li::before { content: "✓"; position: absolute; left: 2px; top: 0; color: var(--g-accent); font-weight: 800; }
.g-planbox__price { font-size: 14px; color: var(--g-muted); margin-bottom: 12px; }
.g-planbox__price strong { color: var(--g-ink); font-size: 16px; }
.g-planbox__note { font-size: 12px; color: var(--g-muted); margin: 10px 0 0; }
.g-planbox__downgrade { margin: 0; }
