* {
    box-sizing: border-box;
}

:root {
    --safe-top: env(safe-area-inset-top, 0px);
    --safe-left: env(safe-area-inset-left, 0px);
    --safe-right: env(safe-area-inset-right, 0px);
    --safe-bottom: env(safe-area-inset-bottom, 0px);
    --ui-top-offset: calc(12px + var(--safe-top));
    --top-control-height: 48px;
    --action-menu-toggle-size: var(--top-control-height);
    --action-menu-toggle-radius: 14px;
    --pin-list-panel-width: min(420px, calc(100vw - 48px));
    --app-panel-bg: rgba(0, 0, 0, 0.5);
    --app-panel-border: rgba(255, 255, 255, 0.2);
    --app-panel-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    --app-panel-blur: blur(10px);
    --app-panel-radius: 15px;
    --app-page-bg: #0b1220;
    --app-text: #e2e8f0;
    --app-text-strong: #f8fafc;
    --app-text-muted: #94a3b8;
    --app-text-soft: #cbd5e1;
    --app-input-bg: rgba(15, 23, 42, 0.4);
    --app-input-border: rgba(148, 163, 184, 0.35);
    --app-input-text: #f8fafc;
    --app-input-placeholder: rgba(226, 232, 240, 0.65);
    --app-button-bg: #111827;
    --app-button-hover: #0f172a;
    --app-button-text: #f8fafc;
    --app-accent: #60a5fa;
    --app-accent-strong: #3b82f6;
    --app-chip-bg: rgba(148, 163, 184, 0.12);
    --app-chip-border: rgba(148, 163, 184, 0.35);
    --app-card-bg: rgba(15, 23, 42, 0.45);
    --app-card-border: rgba(148, 163, 184, 0.3);
    --app-card-shadow: 0 8px 18px rgba(15, 23, 42, 0.25);
    --bottom-nav-height: 64px;
    --bottom-nav-width: min(560px, calc(100vw - 24px - var(--safe-left) - var(--safe-right)));
    --bottom-nav-offset: calc(var(--bottom-nav-height) + 20px + var(--safe-bottom));
}

body[data-theme="light"] {
    --app-panel-bg: rgba(255, 255, 255, 0.9);
    --app-panel-border: rgba(148, 163, 184, 0.45);
    --app-panel-shadow: 0 12px 32px rgba(15, 23, 42, 0.16);
    --app-panel-blur: blur(12px);
    --app-page-bg: #f8fafc;
    --app-text: #0f172a;
    --app-text-strong: #0f172a;
    --app-text-muted: #475569;
    --app-text-soft: #64748b;
    --app-input-bg: rgba(255, 255, 255, 0.9);
    --app-input-border: rgba(148, 163, 184, 0.45);
    --app-input-text: #0f172a;
    --app-input-placeholder: rgba(71, 85, 105, 0.75);
    --app-button-bg: #0f172a;
    --app-button-hover: #1e293b;
    --app-button-text: #f8fafc;
    --app-accent: #2563eb;
    --app-accent-strong: #1d4ed8;
    --app-chip-bg: rgba(148, 163, 184, 0.12);
    --app-chip-border: rgba(148, 163, 184, 0.35);
    --app-card-bg: rgba(241, 245, 249, 0.9);
    --app-card-border: rgba(148, 163, 184, 0.35);
    --app-card-shadow: 0 8px 18px rgba(15, 23, 42, 0.12);
    color-scheme: light;
}

body[data-theme="dark"] {
    color-scheme: dark;
}

body[data-theme="light"] #pin-form .pin-images-hint {
    color: #000000;
}

body[data-theme="dark"] .modal-content {
    background-color: var(--app-panel-bg);
}

body[data-theme="light"] .resident-panel {
    background: #ffffff;
}

body[data-theme="light"] .resident-summary,
body[data-theme="light"] .resident-greeting,
body[data-theme="light"] .resident-kindness,
body[data-theme="light"] .resident-kindness span {
    color: #000000;
}

body[data-theme="light"] .resident-logout-btn {
    color: #000000;
    background: #ffffff;
}

body[data-theme="light"] .resident-status-input-group {
    background: #ffffff;
}

body[data-theme="light"] #resident-status-input {
    background: #ffffff;
    color: #000000;
}

body[data-theme="light"] #unique-ips-count,
body[data-theme="light"] #active-pins-count,
body[data-theme="light"] #live-sellers-count {
    color: #000000;
    background: #ffffff;
}

body[data-theme="light"] #fuel-toggle-container {
    background: #ffffff;
}

body[data-theme="light"] #fuel-toggle-container .toggle-label,
body[data-theme="light"] #fuel-toggle-container .toggle-label.active,
body[data-theme="light"] #fuel-toggle-container .toggle-label-fuel.active,
body[data-theme="light"] #fuel-toggle-container .toggle-label-ev.active {
    color: #000000;
}

body[data-theme="dark"] .pin-list-advanced-label,
body[data-theme="dark"] .pin-list-summary,
body[data-theme="dark"] .pin-list-empty {
    color: var(--app-text);
}

body[data-theme="dark"] .action-menu-heading,
body[data-theme="dark"] .resident-prompt,
body[data-theme="dark"] .action-menu-row-note {
    color: #e2e8f0;
}

body {
    font-family: sans-serif;
    margin: 0;
    padding: 0;
    overflow: hidden;
    color: var(--app-text);
    background: var(--app-page-bg);
}

.maintenance-notice {
    position: fixed;
    top: calc(var(--ui-top-offset) + 4px);
    left: 50%;
    transform: translateX(-50%);
    background: rgba(15, 23, 42, 0.9);
    color: #e2e8f0;
    border: 1px solid rgba(99, 102, 241, 0.35);
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.35);
    border-radius: 14px;
    padding: 12px 14px;
    z-index: 9999;
    display: flex;
    align-items: center;
    gap: 12px;
    width: min(880px, calc(100% - 20px));
    backdrop-filter: blur(8px);
}

.maintenance-notice.hidden {
    display: none;
}

.maintenance-notice__icon {
    width: 32px;
    height: 32px;
    border-radius: 999px;
    background: rgba(99, 102, 241, 0.16);
    color: #f59e0b;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.maintenance-notice__text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.maintenance-notice__title {
    font-weight: 800;
    font-size: 15px;
    letter-spacing: -0.01em;
}

.maintenance-notice__message {
    font-size: 14px;
    color: #cbd5e1;
    line-height: 1.4;
}

body.maintenance-active {
    --app-disabled-opacity: 0.6;
}

body.maintenance-active #map {
    filter: grayscale(0.15);
}

body.maintenance-active #add-pin-btn,
body.maintenance-active #reset-filter-btn,
body.maintenance-active #locate-me-btn,
body.maintenance-active #action-menu-toggle {
    opacity: var(--app-disabled-opacity);
}

#map-type-control-container {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 1;
    background-color: rgba(255, 255, 255, 0.8);
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    overflow: visible;
    display: flex;
    align-items: center;
    padding: 0 8px;
    gap: 4px;
}

.map-type-btn {
    background-color: transparent;
    border: none;
    padding: 10px 15px;
    font-weight: bold;
    color: #333;
}

.map-type-btn.active {
    background-color: #4285f4;
    color: white;
}
#map {
    height: 100vh;
    width: 100%;
}

#map.pin-location-mode {
    box-shadow: inset 0 0 0 3px rgba(14, 165, 233, 0.45);
    transition: box-shadow 0.2s ease;
}

.pin-location-search-bar {
    position: absolute;
    top: calc(var(--ui-top-offset) + 48px);
    left: 50%;
    transform: translateX(-50%);
    z-index: 6;
    background: var(--app-panel-bg);
    border: 1px solid var(--app-panel-border);
    border-radius: var(--app-panel-radius);
    padding: 10px 12px;
    box-shadow: var(--app-panel-shadow);
    width: min(460px, calc(100% - 32px));
    box-sizing: border-box;
}

.pin-location-search-bar.hidden {
    display: none;
}

.pin-location-search-inner {
    display: flex;
    gap: 8px;
    align-items: center;
}

.pin-location-search-inner input {
    flex: 1;
    min-width: 0;
    padding: 11px 12px;
    border-radius: 10px;
    border: 1px solid var(--app-input-border);
    font-size: 14px;
    background: var(--app-input-bg);
    color: var(--app-input-text);
}

.pin-location-search-inner input::placeholder {
    color: var(--app-input-placeholder);
}

.pin-location-search-inner button {
    width: auto;
    padding: 11px 14px;
    border-radius: 10px;
    border: none;
    background: var(--app-button-bg);
    color: var(--app-button-text);
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

.pin-location-search-inner button:hover,
.pin-location-search-inner button:focus-visible {
    background: var(--app-button-hover);
    transform: translateY(-1px);
    outline: none;
}

.pin-location-search-note {
    margin: 8px 4px 0;
    font-size: 12px;
    color: var(--app-text-muted);
}

.pin-location-confirm {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    color: #0f172a;
}

.pin-location-confirm button {
    align-self: flex-end;
    padding: 8px 12px;
    border: none;
    border-radius: 10px;
    background: #0ea5e9;
    color: #fff;
    font-weight: 700;
    cursor: pointer;
}

.pin-location-confirm button:hover,
.pin-location-confirm button:focus-visible {
    background: #0284c7;
    outline: none;
}

.pin-list-panel {
    position: absolute;
    top: var(--ui-top-offset);
    left: calc(12px + var(--safe-left));
    z-index: 4;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    pointer-events: none;
}

.pin-list-search-wrapper {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    pointer-events: auto;
    width: var(--pin-list-panel-width);
}

.pin-list-panel--search-hidden .pin-list-search-wrapper {
    display: none;
}

.pin-list-panel--list-hidden .pin-list-container {
    display: none;
}

.pin-list-search-advanced {
    display: none;
    gap: 8px;
    flex-wrap: wrap;
    pointer-events: auto;
    width: 100%;
}

.pin-list-search-wrapper.pin-list-search-wrapper--advanced-visible .pin-list-search-advanced {
    display: flex;
}

.pin-list-advanced-control {
    position: relative;
    flex: 1 1 160px;
    min-width: 0;
}

.pin-list-advanced-btn {
    width: 100%;
    border: 1px solid var(--app-input-border);
    border-radius: 14px;
    background: var(--app-input-bg);
    color: var(--app-text);
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    text-align: left;
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.pin-list-advanced-btn:hover,
.pin-list-advanced-btn:focus-visible {
    border-color: rgba(59, 130, 246, 0.85);
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.18);
    outline: none;
}

.pin-list-advanced-label {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--app-text-muted);
}

.pin-list-advanced-value {
    font-size: 13px;
    font-weight: 700;
    color: var(--app-text-strong);
}

.pin-list-popover {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    width: var(--pin-list-panel-width);
    max-width: var(--pin-list-panel-width);
    background: var(--app-panel-bg);
    border-radius: 16px;
    border: 1px solid var(--app-panel-border);
    box-shadow: var(--app-panel-shadow);
    padding: 12px;
    pointer-events: auto;
    z-index: 20;
}

.pin-list-popover.hidden {
    display: none;
}

.pin-list-advanced-control:last-child .pin-list-popover {
    left: auto;
    right: 0;
}

.pin-list-popover-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-weight: 700;
    font-size: 13px;
    color: var(--app-text-strong);
    margin-bottom: 6px;
}

.pin-list-popover-header-actions {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.pin-list-popover-body input {
    width: 100%;
    border-radius: 12px;
    border: 1px solid var(--app-input-border);
    padding: 10px 12px;
    font-size: 14px;
    background: var(--app-input-bg);
    color: var(--app-input-text);
}

.pin-list-popover-body input::placeholder {
    color: var(--app-input-placeholder);
}

.pin-list-popover-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 10px;
}

.pin-list-popover-reset {
    border: none;
    background: none;
    color: var(--app-accent-strong);
    font-weight: 700;
    font-size: 12px;
    cursor: pointer;
    padding: 6px 8px;
    border-radius: 8px;
}

.pin-list-popover-reset:hover,
.pin-list-popover-reset:focus-visible {
    background: rgba(37, 99, 235, 0.08);
    outline: none;
}

.pin-list-category-list {
    max-height: 220px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 6px;
    padding-right: 2px;
}

.pin-list-category-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--app-text);
}

.pin-list-category-item input {
    width: 16px;
    height: 16px;
    accent-color: var(--app-accent-strong);
    cursor: pointer;
}

.pin-list-category-item span {
    flex: 1;
    line-height: 1.3;
}

.pin-list-search-field {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--app-input-bg);
    border-radius: 16px;
    border: 1px solid var(--app-input-border);
    padding: 6px 6px 6px 14px;
    height: var(--top-control-height);
    box-shadow: var(--app-panel-shadow);
}

.pin-list-search-field input {
    flex: 1;
    min-width: 0;
    border: none;
    background: transparent;
    font-size: 14px;
    color: var(--app-input-text);
    padding: 8px 0;
}

.pin-list-search-field input::placeholder {
    color: var(--app-input-placeholder);
}

.pin-list-search-field input:focus {
    outline: none;
}

.pin-list-search-submit {
    border: none;
    border-radius: 12px;
    padding: 10px 18px;
    background: var(--app-button-bg);
    color: var(--app-button-text);
    font-weight: 700;
    font-size: 13px;
    letter-spacing: 0.02em;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

.pin-list-search-submit:hover,
.pin-list-search-submit:focus-visible {
    background: var(--app-button-hover);
    transform: translateY(-1px);
    outline: none;
}

.pin-list-search-submit:active {
    transform: translateY(0);
}

.pin-list-search-reset {
    border: 1px solid var(--app-chip-border);
    border-radius: 12px;
    padding: 10px 14px;
    background: var(--app-chip-bg);
    color: var(--app-text);
    font-weight: 700;
    font-size: 12px;
    letter-spacing: 0.02em;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.pin-list-search-reset:hover,
.pin-list-search-reset:focus-visible {
    background: var(--app-button-bg);
    color: var(--app-button-text);
    border-color: var(--app-button-bg);
    transform: translateY(-1px);
    outline: none;
}

.pin-list-search-reset:active {
    transform: translateY(0);
}

.pin-list-panel--collapsed .pin-list-search-field {
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.2);
}

.pin-list-panel.pin-list-panel--stacked {
    top: var(--ui-top-offset);
}

.action-menu-toggle {
    pointer-events: auto;
    border: none;
    background: transparent;
    padding: 0;
    width: var(--action-menu-toggle-size);
    height: var(--action-menu-toggle-size);
    border-radius: var(--action-menu-toggle-radius);
    box-shadow: var(--app-panel-shadow);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.action-menu-toggle__avatar {
    width: 100%;
    height: 100%;
    border-radius: inherit;
    background: var(--app-panel-bg);
    color: var(--app-text);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 20px;
    text-transform: uppercase;
    border: 1px solid var(--app-panel-border);
    overflow: hidden;
    box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.2);
}

.action-menu-toggle__photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
}

.action-menu-toggle__fallback {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    letter-spacing: 0.04em;
    line-height: 1;
}

.action-menu-toggle--has-photo .action-menu-toggle__photo {
    display: block;
}

.action-menu-toggle--has-photo .action-menu-toggle__fallback {
    display: none;
}

.action-menu-toggle:hover {
    box-shadow: 0 14px 32px rgba(15, 23, 42, 0.4);
    transform: translateY(-2px);
}

.action-menu-toggle:focus-visible {
    outline: none;
}

.action-menu-toggle:focus-visible .action-menu-toggle__avatar {
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.35);
}

.pin-list-container {
    pointer-events: auto;
    width: var(--pin-list-panel-width);
    max-width: var(--pin-list-panel-width);
    max-height: calc(100vh - 170px);
    padding: 14px;
    background: var(--app-panel-bg);
    color: var(--app-text);
    border-radius: var(--app-panel-radius);
    box-shadow: var(--app-panel-shadow);
    backdrop-filter: var(--app-panel-blur);
    border: 1px solid var(--app-panel-border);
    display: flex;
    flex-direction: column;
    gap: 12px;
    transform: translateY(0);
    opacity: 1;
    transition: transform 0.24s ease, opacity 0.24s ease;
}

.pin-list-panel--collapsed .pin-list-container {
    transform: translateY(-12px);
    opacity: 0;
    pointer-events: none;
}

.pin-list-header {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.pin-list-header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.pin-list-title {
    font-size: 15px;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--app-accent);
}

.pin-list-kategori-link {
    display: inline-flex;
    align-items: center;
    padding: 6px 10px;
    border-radius: 999px;
    border: 1px solid var(--app-chip-border);
    background: var(--app-chip-bg);
    color: var(--app-text);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    text-decoration: none;
    white-space: nowrap;
}

.pin-list-kategori-link:hover {
    color: var(--app-text-strong);
    border-color: var(--app-accent);
}

.pin-list-kategori-link:focus-visible {
    outline: 2px solid var(--app-accent);
    outline-offset: 2px;
}

.pin-list-summary {
    font-size: 13px;
    color: var(--app-text-muted);
}

.pin-list-empty {
    padding: 12px;
    border-radius: 12px;
    background: var(--app-chip-bg);
    border: 1px dashed var(--app-chip-border);
    font-size: 13px;
    color: var(--app-text-muted);
}

.pin-list-empty.hidden {
    display: none;
}

.pin-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow-y: auto;
    padding-right: 0;
}

.pin-list-item {
    width: 100%;
    border: 1px solid var(--app-panel-border);
    border-radius: var(--app-panel-radius);
    background: var(--app-panel-bg);
    color: var(--app-text);
    padding: 16px 18px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    text-align: left;
    cursor: pointer;
    transition: background 0.25s ease, border-color 0.25s ease, transform 0.15s ease, box-shadow 0.25s ease;
    box-shadow: var(--app-panel-shadow);
    backdrop-filter: var(--app-panel-blur);
}

.pin-list-item:hover,
.pin-list-item:focus-visible {
    background: var(--app-card-bg);
    border-color: var(--app-card-border);
    box-shadow: var(--app-card-shadow);
    outline: none;
    transform: translateY(-2px);
}

.pin-list-item__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.pin-list-item__actions {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: auto;
}

.pin-list-item__save,
.pin-list-item__share {
    border: 1px solid var(--app-chip-border);
    background: var(--app-chip-bg);
    color: var(--app-text);
    border-radius: 999px;
    padding: 6px 10px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.pin-list-item__save:hover,
.pin-list-item__save:focus-visible,
.pin-list-item__share:hover,
.pin-list-item__share:focus-visible {
    background: rgba(96, 165, 250, 0.2);
    border-color: rgba(96, 165, 250, 0.4);
    outline: none;
}

.pin-list-item__save.is-saved {
    background: var(--app-accent-strong);
    border-color: var(--app-accent-strong);
    color: var(--app-button-text);
}

.pin-list-item__calendar {
    border: 1px solid rgba(34, 197, 94, 0.45);
    background: rgba(34, 197, 94, 0.12);
    color: var(--app-text-strong);
    border-radius: 999px;
    padding: 6px 10px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.pin-list-item__calendar:hover,
.pin-list-item__calendar:focus-visible {
    background: rgba(34, 197, 94, 0.24);
    border-color: rgba(34, 197, 94, 0.6);
    outline: none;
}

.pin-list-item__calendar:disabled {
    background: var(--app-chip-bg);
    border-color: var(--app-chip-border);
    color: var(--app-text-muted);
    cursor: not-allowed;
    opacity: 0.7;
}

.pin-list-item--saved {
    border-color: rgba(59, 130, 246, 0.45);
}

.pin-list-item__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: nowrap;
}

.pin-list-item__title {
    font-weight: 800;
    font-size: 17px;
    color: var(--app-text-strong);
    text-decoration: none;
}

.pin-list-item__distance {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 78px;
    white-space: nowrap;
    flex-shrink: 0;
    font-size: 12px;
    font-weight: 700;
    color: var(--app-accent);
    background: var(--app-chip-bg);
    padding: 4px 8px;
    border-radius: 999px;
    border: 1px solid var(--app-chip-border);
}

.pin-list-item__category {
    font-size: 12px;
    color: var(--app-text-muted);
    letter-spacing: 0.02em;
}

.pin-list-item__date {
    font-size: 12px;
    color: var(--app-text-soft);
    letter-spacing: 0.01em;
}

.pin-list-item__desc {
    font-size: 14px;
    color: var(--app-text);
    line-height: 1.4;
}

.pin-list-item__meta {
    display: grid;
    grid-template-columns: repeat(4, minmax(64px, 1fr));
    gap: 8px;
}

.pin-meta-card {
    background: var(--app-card-bg);
    color: var(--app-text);
    border: 1px solid var(--app-card-border);
    border-radius: 16px;
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    box-shadow: var(--app-card-shadow);
    min-height: 76px;
    align-items: center;
    text-align: center;
}

.pin-meta-card--category {
    background: var(--app-card-bg);
}

.pin-meta-card--category .pin-meta-card__value {
    font-size: 16px;
    line-height: 1.25;
    white-space: normal;
    word-break: break-word;
    padding: 0 4px;
}


.pin-meta-card__label {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.01em;
    color: var(--app-text-muted);
}

.pin-meta-card__value {
    font-size: 20px;
    font-weight: 800;
    line-height: 1;
    color: var(--app-text-strong);
}

.pin-meta-card__sub {
    font-size: 10px;
    font-weight: 700;
    color: var(--app-text-muted);
    opacity: 0.95;
}

.pin-list-item__description-block {
    display: flex;
    flex-direction: column;
    gap: 6px;
    background: var(--app-input-bg);
    border: 1px solid var(--app-input-border);
    border-radius: 12px;
    padding: 10px 12px;
}

.pin-list-item__desc-title {
    font-weight: 700;
    font-size: 14px;
    color: var(--app-text-strong);
}

.pin-list-item__date-range {
    font-size: 12px;
    color: var(--app-text-muted);
}

.pin-list-item__more-btn {
    background: none;
    border: none;
    color: var(--app-accent);
    font-weight: 700;
    font-style: italic;
    padding: 0;
    text-decoration: underline;
    cursor: pointer;
    align-self: flex-start;
}

.pin-list-item__more-btn:hover {
    color: var(--app-accent-strong);
}

.pin-list-item__detail {
    font-size: 12px;
    font-weight: 700;
    color: var(--app-accent);
    text-decoration: underline;
    align-self: flex-start;
}

.pin-list-item__detail:hover,
.pin-list-item__detail:focus-visible {
    color: var(--app-accent-strong);
    outline: none;
}

@media (max-width: 768px) {
    :root {
        --pin-list-panel-width: min(380px, calc(100vw - 48px));
    }
    .pin-list-panel {
        top: var(--ui-top-offset);
        left: calc(12px + var(--safe-left));
    }
    .pin-list-container {
        width: var(--pin-list-panel-width);
        max-width: var(--pin-list-panel-width);
        max-height: calc(100vh - 190px);
    }
    .pin-list-item__meta {
        grid-template-columns: repeat(4, minmax(60px, 1fr));
        gap: 6px;
    }
    .pin-meta-card {
        padding: 7px;
        min-height: 72px;
    }
}

.action-menu {
    position: absolute;
    top: var(--ui-top-offset);
    right: calc(12px + var(--safe-right));
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
}

.action-menu.open .action-menu-toggle .action-menu-toggle__avatar {
    border-color: rgba(59, 130, 246, 0.85);
    box-shadow: inset 0 0 0 1px rgba(59, 130, 246, 0.35);
}

.action-menu-content {
    display: none;
    width: min(320px, calc(100vw - 24px));
    padding: 20px 16px 16px;
    margin-top: 24px;
    border-radius: var(--app-panel-radius);
    background: var(--app-panel-bg);
    box-shadow: var(--app-panel-shadow);
    backdrop-filter: var(--app-panel-blur);
    color: var(--app-text);
    flex-direction: column;
    gap: 20px;
    max-height: 75vh;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    border: 1px solid var(--app-panel-border);
}

.action-menu.open .action-menu-content {
    display: flex;
}

.action-menu-content.hidden {
    display: none;
}

.action-menu-section {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.action-menu-section.hidden {
    display: none;
}

.action-menu-section:not(:last-child) {
    padding-bottom: 14px;
    border-bottom: 1px solid rgba(148, 163, 184, 0.18);
}

.action-menu-heading {
    margin: 0;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--app-text-muted);
}

.action-menu-row {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.action-menu-content .map-type-row {
    gap: 6px;
    padding: 4px;
    border-radius: 999px;
    background: var(--app-input-bg);
    border: 1px solid var(--app-input-border);
    width: 100%;
}

.theme-toggle {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px;
    border-radius: 999px;
    background: var(--app-input-bg);
    border: 1px solid var(--app-input-border);
    width: 100%;
}

.theme-toggle-btn {
    flex: 1;
    border: none;
    border-radius: 999px;
    padding: 8px 12px;
    background: transparent;
    color: var(--app-text-muted);
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.theme-toggle-btn.is-active {
    background: var(--app-button-bg);
    color: var(--app-button-text);
}

.theme-toggle-btn:focus-visible {
    outline: 2px solid var(--app-accent);
    outline-offset: 2px;
}

.action-menu-info-btn {
    width: 100%;
    justify-content: center;
    font-weight: 700;
}

.action-menu-add-pin {
    width: 100%;
    justify-content: center;
    border-radius: 12px;
    padding: 10px 16px;
    border: 1px solid var(--app-accent-strong);
    background: var(--app-accent-strong);
    color: var(--app-button-text);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.action-menu-add-pin:hover,
.action-menu-add-pin:focus-visible {
    background: var(--app-accent);
    border-color: var(--app-accent);
    transform: translateY(-1px);
    outline: none;
}

.action-menu-row-note {
    font-size: 12px;
    color: var(--app-text-muted);
    flex: 1 1 auto;
}

.menu-pill-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 64px;
    padding: 8px 14px;
    border-radius: 999px;
    border: 1px solid var(--app-chip-border);
    background: var(--app-chip-bg);
    color: var(--app-text);
    font-size: 13px;
    font-weight: 600;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.action-menu-content .map-type-btn {
    flex: 1;
    border: none;
    border-radius: 999px;
    padding: 8px 12px;
    background: transparent;
    color: var(--app-text-muted);
    font-size: 12px;
    font-weight: 700;
    transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.action-menu-content .map-type-btn.active {
    background: var(--app-button-bg);
    color: var(--app-button-text);
}

.action-menu-content .map-type-btn:focus-visible {
    outline: 2px solid var(--app-accent);
    outline-offset: 2px;
}

.menu-pill-btn:hover {
    background: rgba(96, 165, 250, 0.2);
    border-color: rgba(96, 165, 250, 0.4);
}

.bottom-nav {
    position: fixed;
    left: 50%;
    bottom: calc(12px + var(--safe-bottom));
    transform: translateX(-50%);
    z-index: 8;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 6px;
    padding: 10px 12px;
    width: var(--bottom-nav-width);
    min-height: var(--bottom-nav-height);
    background: var(--app-panel-bg);
    border: 1px solid var(--app-panel-border);
    border-radius: 18px;
    box-shadow: var(--app-panel-shadow);
    backdrop-filter: var(--app-panel-blur);
}

.bottom-nav__btn {
    border: 1px solid transparent;
    background: transparent;
    color: var(--app-text-muted);
    font-size: 12px;
    font-weight: 700;
    border-radius: 12px;
    padding: 8px 6px;
    cursor: pointer;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.bottom-nav__btn:hover,
.bottom-nav__btn:focus-visible {
    background: rgba(96, 165, 250, 0.18);
    border-color: rgba(96, 165, 250, 0.35);
    color: var(--app-text-strong);
    outline: none;
}

.bottom-nav__btn.is-active {
    background: var(--app-button-bg);
    border-color: var(--app-button-bg);
    color: var(--app-button-text);
}

.bottom-nav__btn.is-disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.bottom-nav__label {
    font-size: 12px;
    font-weight: 700;
}

.bottom-nav__item {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bottom-nav__item--menu {
    position: relative;
}

.bottom-nav .action-menu {
    position: relative;
    top: auto;
    right: auto;
    z-index: auto;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.bottom-nav .action-menu-content {
    position: absolute;
    bottom: calc(100% + 12px);
    right: 0;
    z-index: 9;
}

.bottom-nav .action-menu-toggle {
    width: 100%;
    height: auto;
    padding: 6px 10px;
    border-radius: 12px;
    box-shadow: none;
    background: var(--app-input-bg);
    border: 1px solid var(--app-input-border);
}

.bottom-nav .action-menu-toggle__avatar {
    width: 28px;
    height: 28px;
    border-radius: 999px;
    font-size: 14px;
}

.bottom-nav .action-menu-toggle:hover {
    box-shadow: none;
    transform: translateY(-1px);
}

.travel-mode-btn {
    min-width: 44px;
    height: 44px;
    padding: 0;
    font-size: 22px;
    line-height: 1;
}

.travel-mode-btn.active {
    background: rgba(59, 130, 246, 0.35);
    border-color: rgba(59, 130, 246, 0.6);
    color: #dbeafe;
}

.fuel-toggle-wrapper {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding-top: 0;
}

#locate-me-btn {
    position: absolute;
    bottom: var(--bottom-nav-offset);
    z-index: 1;
    background-color: var(--app-accent-strong);
    color: var(--app-button-text);
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    font-size: 30px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s;
}

#locate-me-btn {
    left: auto;
    right: 24px;
    bottom: var(--bottom-nav-offset);
    width: 44px;
    height: 44px;
    font-size: 22px;
    transform: rotate(-45deg);
}

#locate-me-btn:hover {
    transform: scale(1.1);
}

.reset-rotating {
    animation: reset-spin 0.6s ease;
}

@keyframes reset-spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

#pin-form {
    position: fixed;
    left: 50%;
    bottom: calc(var(--bottom-nav-offset) + 12px);
    z-index: 7;
    width: min(520px, calc(100vw - 24px));
    max-height: calc(100vh - (var(--bottom-nav-offset) + 48px));
    padding: 20px 18px;
    border-radius: var(--app-panel-radius);
    background: var(--app-panel-bg);
    border: 1px solid var(--app-panel-border);
    box-shadow: var(--app-panel-shadow);
    backdrop-filter: var(--app-panel-blur);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    transition: transform 0.25s ease, opacity 0.2s ease, visibility 0.2s ease;
}

#pin-form:not(.hidden) {
    transform: translate(-50%, 0);
    opacity: 1;
    visibility: visible;
}

#pin-form.hidden {
    transform: translate(-50%, 110vh);
    opacity: 0;
    visibility: hidden;
}

#pin-form h2 {
    margin-top: 0;
    color: var(--app-text-strong);
    text-align: center;
}

#pin-form input,
#pin-form select,
#pin-form textarea,
#pin-form #lifetime-date-picker {
    display: block;
    width: calc(100% - 10px);
    margin-bottom: 15px;
    padding: 12px;
    border: 1px solid var(--app-input-border);
    border-radius: 10px;
    background-color: var(--app-input-bg);
    color: var(--app-input-text);
    font-size: 14px;
}

#pin-form input::placeholder,
#pin-form textarea::placeholder {
    color: var(--app-input-placeholder);
    font-family: sans-serif;
}

#pin-form .pin-location-field {
    margin-bottom: 15px;
    padding: 12px;
    border-radius: 12px;
    background: var(--app-input-bg);
    border: 1px solid var(--app-input-border);
}

#pin-form .pin-location-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 10px;
}

#pin-form .pin-location-btn {
    border: none;
    background: var(--app-accent-strong);
    color: var(--app-button-text);
    padding: 10px 12px;
    border-radius: 10px;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

#pin-form .pin-location-btn:hover,
#pin-form .pin-location-btn:focus-visible {
    background: var(--app-accent);
    transform: translateY(-1px);
    outline: none;
}

#pin-form .pin-location-hint {
    margin: 0 0 6px;
    font-size: 12px;
    color: var(--app-text-muted);
}

#pin-form .pin-location-coordinates {
    display: flex;
    gap: 8px;
    align-items: center;
}

#pin-form .pin-location-coordinates span {
    flex: 1;
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid rgba(148, 163, 184, 0.35);
    border-radius: 10px;
    padding: 8px;
    font-size: 12px;
    font-weight: 700;
    color: #0f172a;
    text-align: center;
}

#pin-form .pin-images-field {
    margin-bottom: 15px;
}

#pin-form .pin-images-field label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 6px;
    color: var(--app-text);
}

#pin-form .pin-images-hint {
    margin: 8px 0 0;
    font-size: 12px;
    color: #e2e8f0;
}

#pin-form .pin-images-preview {
    margin: 10px 0 0;
    padding: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

#pin-form .pin-images-preview.hidden {
    display: none;
}

#pin-form .pin-images-preview__item {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    background: rgba(241, 245, 249, 0.85);
    border: 1px solid rgba(148, 163, 184, 0.35);
    border-radius: 10px;
    padding: 6px 10px;
    font-size: 12px;
    color: #1f2937;
}

#pin-form .pin-images-preview__details {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

#pin-form .pin-images-preview__thumb {
    width: 56px;
    height: 56px;
    border-radius: 10px;
    overflow: hidden;
    flex-shrink: 0;
    background: rgba(148, 163, 184, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
}

#pin-form .pin-images-preview__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

#pin-form .pin-images-preview__thumb--empty {
    color: #475569;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

#pin-form .pin-images-preview__remove {
    border: none;
    background: rgba(239, 68, 68, 0.85);
    color: #fff;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease;
}

#pin-form .pin-images-preview__remove:hover,
#pin-form .pin-images-preview__remove:focus-visible {
    background: rgba(220, 38, 38, 0.95);
    outline: none;
}

#pin-form .pin-existing-images {
    margin: 12px 0;
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(15, 23, 42, 0.04);
    border: 1px solid rgba(148, 163, 184, 0.35);
}

#pin-form .pin-existing-images.hidden {
    display: none;
}

#pin-form .pin-existing-images__title {
    font-size: 12px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

#pin-form .pin-existing-images__hint {
    font-size: 11px;
    color: #64748b;
    margin: 8px 0 0;
}

#pin-form .pin-existing-images__list {
    display: flex;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

#pin-form .pin-existing-images__list::-webkit-scrollbar {
    height: 6px;
}

#pin-form .pin-existing-images__list::-webkit-scrollbar-thumb {
    background: rgba(148, 163, 184, 0.6);
    border-radius: 999px;
}

#pin-form .pin-existing-images__list::-webkit-scrollbar-track {
    background: rgba(15, 23, 42, 0.2);
}

#pin-form .pin-existing-images__item {
    position: relative;
    flex: 0 0 84px;
    height: 84px;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, 0.4);
    background: rgba(241, 245, 249, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
}

#pin-form .pin-existing-images__item--removed {
    opacity: 0.45;
    border-style: dashed;
}

#pin-form .pin-existing-images__thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

#pin-form .pin-existing-images__actions {
    position: absolute;
    left: 6px;
    right: 6px;
    bottom: 6px;
    display: flex;
    justify-content: center;
}

#pin-form .pin-existing-images__btn {
    border: none;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
    padding: 4px 10px;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

#pin-form .pin-existing-images__btn--remove {
    background: rgba(239, 68, 68, 0.85);
    color: #fff;
}

#pin-form .pin-existing-images__btn--remove:hover,
#pin-form .pin-existing-images__btn--remove:focus-visible {
    background: rgba(220, 38, 38, 0.95);
    outline: none;
}

#pin-form .pin-existing-images__btn--restore {
    background: rgba(34, 197, 94, 0.85);
    color: #fff;
}

#pin-form .pin-existing-images__btn--restore:hover,
#pin-form .pin-existing-images__btn--restore:focus-visible {
    background: rgba(22, 163, 74, 0.95);
    outline: none;
}

#pin-form button {
    display: block;
    width: 100%;
    padding: 15px;
    border: none;
    border-radius: 10px;
    background-color: var(--app-accent-strong);
    color: var(--app-button-text);
    font-size: 16px;
    transition: background-color 0.2s;
}

#pin-form button:hover {
    background-color: var(--app-accent);
}

#lifetime-date-picker {
    margin-top: 10px;
}

#metrics-container {
    display: grid;
    gap: 8px;
}

#metrics-container > div {
    background: rgba(30, 41, 59, 0.55);
    border: 1px solid rgba(148, 163, 184, 0.35);
    border-radius: 12px;
    padding: 12px 14px;
    font-weight: 600;
    font-size: 0.85rem;
    color: #e2e8f0;
}

.metric-updated {
    animation: metric-pulse 0.6s ease;
}

@keyframes metric-pulse {
    0% {
        transform: scale(1);
    }
    40% {
        transform: scale(1.12);
    }
    100% {
        transform: scale(1);
    }
}



.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.modal-overlay.hidden {
    opacity: 0;
    pointer-events: none;
}

.modal-content {
    background-color: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(10px);
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.2);
    width: 90%;
    max-height: 80%;
    max-width: 500px;
    position: relative;
    transform: translateY(0);
    transition: transform 0.3s ease;
    overflow-y: auto; /* Added this line */
}

.modal-overlay.hidden .modal-content {
    transform: translateY(-20px);
}

.close-btn {
    position: absolute;
    top: 10px;
    right: 15px;
    background: none;
    border: none;
    font-size: 28px;
    color: #aaa;
}

.close-btn:hover {
    color: #333;
}

.custom-info-window {
    position: absolute;
    background: var(--app-panel-bg);
    backdrop-filter: var(--app-panel-blur);
    border-radius: var(--app-panel-radius, 15px);
    color: var(--app-text);
    padding: 20px;
    width: 300px;
    box-shadow: var(--app-panel-shadow);
    border: 1px solid var(--app-panel-border);
    transform: translate(-50%, -110%);
}

.info-window-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.info-window-category {
    font-weight: bold;
    font-size: 1.618em;
    color: var(--app-accent);
}

.close-info-window {
    background: none;
    border: none;
    color: var(--app-text);
    font-size: 24px;
}

.info-window-title {
    font-weight: bold;
    font-size: 1.5em;
    margin-bottom: 10px;
}

.info-window-description {
    margin-bottom: 20px;
    font-size: 1.2em;
}

.info-window-images {
    display: flex;
    gap: 10px;
    margin: 12px 0;
    padding: 0;
    list-style: none;
    align-items: center;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: rgba(148, 163, 184, 0.6) rgba(15, 23, 42, 0.35);
}

.info-window-images::-webkit-scrollbar {
    height: 6px;
}

.info-window-images::-webkit-scrollbar-thumb {
    background: rgba(148, 163, 184, 0.6);
    border-radius: 999px;
}

.info-window-images::-webkit-scrollbar-track {
    background: rgba(15, 23, 42, 0.35);
}

.info-window-images__item {
    flex: 0 0 96px;
    height: 96px;
    border-radius: 10px;
    overflow: hidden;
    background: rgba(15, 23, 42, 0.6);
    cursor: zoom-in;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.info-window-images__item:hover,
.info-window-images__item:focus-within {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.35);
}

.info-window-images__item img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    cursor: inherit;
}

.info-window-when {
    font-size: 1.2em;
    color: var(--app-text-muted);
    margin-bottom: 10px;
}

.info-window-link {
    font-size: 1.2em;
    color: #2563eb;
    text-decoration: none;
    margin-bottom: 15px;
    margin-top: 15px;
    word-wrap: break-word;
}

.info-window-link a {
    color: inherit;
    text-decoration: none;
}

.info-window-detail {
    display: none;
    font-size: 1.1em;
    margin-bottom: 12px;
}

.info-window-detail a {
    color: var(--app-accent);
    text-decoration: underline;
}

.info-window-actions {
    margin: 12px 0;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    gap: 12px;
}

.info-window-actions .edit-btn {
    margin-right: auto;
}

.save-pin-btn,
.share-pin-btn {
    border: 1px solid var(--app-chip-border);
    background: var(--app-chip-bg);
    color: var(--app-text);
    border-radius: 999px;
    padding: 8px 14px;
    font-size: 0.85em;
    font-weight: 700;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.save-pin-btn:hover,
.save-pin-btn:focus-visible,
.share-pin-btn:hover,
.share-pin-btn:focus-visible {
    background: rgba(96, 165, 250, 0.2);
    border-color: rgba(96, 165, 250, 0.4);
    outline: none;
    transform: translateY(-1px);
}

.save-pin-btn.is-saved {
    background: var(--app-accent-strong);
    border-color: var(--app-accent-strong);
    color: var(--app-button-text);
}

.navigate-btn {
    background-color: #34a853;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    padding: 10px 16px;
    font-size: 0.95em;
    font-weight: 600;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.navigate-btn:hover,
.navigate-btn:focus {
    background-color: #2c8d45;
    transform: translateY(-1px);
}

.navigation-modal {
    position: fixed;
    inset: 0;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    background: rgba(0, 0, 0, 0.35);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.25s ease, visibility 0.25s ease;
    z-index: 1500;
}

.navigation-modal--open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.navigation-modal__sheet {
    width: 100%;
    max-width: 420px;
    background: rgba(12, 18, 34, 0.92);
    color: #f1f5f9;
    border-radius: 18px 18px 0 0;
    padding: 16px 20px 14px;
    transform: translateY(32px);
    transition: transform 0.25s ease;
    backdrop-filter: blur(18px);
    box-shadow: 0 -20px 40px rgba(0, 0, 0, 0.35);
}

.navigation-modal--open .navigation-modal__sheet {
    transform: translateY(0);
}

.navigation-modal__handle {
    width: 48px;
    height: 4px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.25);
    margin: 0 auto 12px;
}

.navigation-modal__title {
    font-size: 1.1em;
    font-weight: 600;
    margin: 0 0 12px;
    text-align: center;
    color: #f8fafc;
}

.navigation-modal__options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.navigation-modal__option {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.08);
    border: none;
    border-radius: 12px;
    padding: 14px 16px;
    color: inherit;
    text-align: left;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.navigation-modal__option:hover,
.navigation-modal__option:focus {
    background: rgba(66, 133, 244, 0.25);
    transform: translateY(-1px);
}

.navigation-modal__option-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.navigation-modal__option-title {
    font-size: 1em;
    font-weight: 600;
    color: #f8fafc;
}

.navigation-modal__option-hint {
    font-size: 0.8em;
    color: rgba(241, 245, 249, 0.75);
}

.navigation-modal__option-arrow {
    font-size: 1.2em;
    color: rgba(241, 245, 249, 0.6);
}

.navigation-modal__cancel {
    margin-top: 14px;
    width: 100%;
    background: rgba(255, 255, 255, 0.15);
    border: none;
    border-radius: 12px;
    padding: 12px;
    color: #f8fafc;
    font-size: 0.95em;
    font-weight: 600;
    transition: background-color 0.2s ease;
}

.navigation-modal__cancel:hover,
.navigation-modal__cancel:focus {
    background: rgba(255, 255, 255, 0.25);
}

.info-window-vote {
    margin-top: 10px;
    display: flex;
    align-items: center;
    font-size: 1.5em;
}

.info-window-vote button {
    background: none;
    border: none;
    font-size: 20px;
    margin-right: 5px;
    color: white;
}

.info-window-vote span {
    margin-right: 15px;
}

.edit-btn {
    background-color: #4285f4;
    color: white;
    border: none;
    border-radius: 5px;
    padding: 10px 15px;
    font-size: 14px;
    margin-left: 0px;
}

.edit-btn:hover {
    background-color: #357ae8;
    color: #ffffff;
}

.info-window-vote-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 10px;
}

.info-window-vote-actions .info-window-vote {
    margin: 0;
}
#install-app-btn,
#update-app-btn,
#info-btn,
.action-menu-add-pin {
    width: 100%;
    padding: 12px 14px;
    border-radius: 12px;
    border: none;
    color: #f8fafc;
    font-weight: 700;
    font-size: 0.95rem;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.28);
    transition: transform 0.2s ease, background 0.2s ease;
    cursor: pointer;
    text-align: center;
}

#install-app-btn,
#update-app-btn,
#info-btn,
.action-menu-add-pin {
    background: linear-gradient(135deg, #52a4ff, #3f7bff);
}

#install-app-btn:hover,
#install-app-btn:focus,
#update-app-btn:hover,
#update-app-btn:focus,
#info-btn:hover,
#info-btn:focus,
.action-menu-add-pin:hover,
.action-menu-add-pin:focus-visible {
    background: linear-gradient(135deg, #3f8bf5, #316acc);
    transform: translateY(-1px);
    outline: none;
}

#install-app-btn[hidden],
#update-app-btn[hidden] {
    display: none;
}

#fuel-toggle-container {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    background: var(--app-input-bg);
    border-radius: 12px;
    border: 1px solid var(--app-input-border);
    font-weight: 700;
    text-transform: uppercase;
    align-self: flex-start;
    width: fit-content;
}

#fuel-toggle-container .toggle-label {
    font-size: 12px;
    letter-spacing: 0.06em;
    color: #94a3b8;
    transition: color 0.2s ease;
}

#fuel-toggle-container .toggle-label.active {
    color: #22344d;
}

#fuel-toggle-container .toggle-label-fuel.active {
    color: #ef4444;
}

#fuel-toggle-container .toggle-label-ev.active {
    color: #22c55e;
}

.cluster-marker {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(66, 133, 244, 0.9);
    color: #fff;
    font-weight: 600;
    border: 2px solid #ffffff;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
    font-size: 14px;
}

.toggle-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 24px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
    position: absolute;
}

.toggle-slider {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ef4444;
    border-radius: 999px;
    transition: background-color 0.2s ease;
}

.toggle-slider::before {
    position: absolute;
    content: '';
    height: 20px;
    width: 20px;
    left: 2px;
    top: 2px;
    background-color: #ffffff;
    border-radius: 50%;
    transition: transform 0.2s ease;
}

.toggle-switch input:checked + .toggle-slider::before {
    transform: translateX(24px);
}

#special-category-on-btn,
#special-category-off-btn {
    position: static;
    box-shadow: none;
}

#special-category-on-btn.active {
    background: rgba(74, 222, 128, 0.25);
    border-color: rgba(74, 222, 128, 0.45);
    color: #bbf7d0;
}

#special-category-off-btn.active {
    background: rgba(74, 222, 128, 0.25);
    border-color: rgba(74, 222, 128, 0.45);
    color: #bbf7d0;
}

#special-category-on-btn:disabled,
#special-category-off-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

#fuel-toggle-container[data-mode="fuel"] .toggle-slider {
    background-color: #ef4444;
}

#fuel-toggle-container[data-mode="ev"] .toggle-slider {
    background-color: #22c55e;
}

.toggle-switch input:disabled + .toggle-slider {
    cursor: not-allowed;
    opacity: 0.5;
}

#fuel-toggle-container[data-disabled="true"] {
    opacity: 0.6;
}

#fuel-toggle-container[data-disabled="true"] .toggle-switch {
    pointer-events: none;
}

#fuel-toggle-container[data-disabled="true"] .toggle-slider {
    background-color: #d1d5db;
}

#fuel-toggle-container[data-disabled="true"] .toggle-label {
    color: #64748b;
}

/* Panel Gerobak Online */
.live-seller-panel {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 14px;
    border-radius: 14px;
    background: rgba(15, 23, 42, 0.4);
    border: 1px solid rgba(148, 163, 184, 0.22);
    color: #f8fafc;
}

.live-seller-panel.hidden {
    display: none;
}

.live-seller-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
}

.live-seller-panel-title {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.live-seller-label {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #cbd5f5;
}

.live-seller-status {
    padding: 6px 0px 0px 0px;
    font-size: 14px;
    font-weight: 600;
    color: #f0f9ff;
}

.live-seller-status.offline {
    color: #f87171;
}

.live-seller-status.online {
    color: #4ade80;
}

.live-seller-panel-actions {
    display: flex;
    gap: 8px;
}

.live-seller-secondary-btn {
    padding: 6px 12px;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.35);
    background: rgba(148, 163, 184, 0.12);
    color: #e2e8f0;
    font-size: 12px;
    font-weight: 600;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.live-seller-secondary-btn:hover {
    background: rgba(148, 163, 184, 0.25);
    border-color: rgba(148, 163, 184, 0.55);
}

.live-seller-profile {
    display: flex;
    align-items: center;
    gap: 12px;
}

.live-seller-profile.hidden {
    display: none;
}

.live-seller-photo {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    object-fit: cover;
    background: rgba(148, 163, 184, 0.2);
}

.live-seller-photo.hidden {
    display: none;
}

.live-seller-profile-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.live-seller-community-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(74, 222, 128, 0.15);
    color: #bbf7d0;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.live-seller-community-badge.hidden {
    display: none;
}

.live-seller-name {
    font-size: 15px;
    font-weight: 600;
    color: #f8fafc;
}

.live-seller-brand {
    font-size: 13px;
    color: #cbd5f5;
}

.live-seller-brand.hidden {
    display: none;
}

.live-seller-phone {
    font-size: 13px;
    color: #86efac;
    text-decoration: none;
}

.live-seller-phone.hidden {
    display: none;
}

.live-seller-primary-btn {
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, #34d399, #10b981);
    color: #0f172a;
    font-weight: 700;
    font-size: 14px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.live-seller-primary-btn:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 12px 28px rgba(16, 185, 129, 0.35);
}

.live-seller-primary-btn:disabled {
    cursor: not-allowed;
    opacity: 0.55;
    box-shadow: none;
}

.live-seller-links-authenticated.hidden,
.live-seller-auth-links.hidden {
    display: none;
}

.live-seller-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.live-seller-menu-link {
    text-decoration: none;
}

.live-seller-menu-link:hover {
    text-decoration: none;
    background: rgba(96, 165, 250, 0.2);
    border-color: rgba(96, 165, 250, 0.4);
}

.resident-panel {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.resident-panel-body {
    margin-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.resident-panel-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 4px;
}

.resident-panel-links .menu-pill-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    border-radius: 999px;
}

.resident-summary {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.resident-greeting {
    font-weight: 600;
    font-size: 14px;
    color: #f8fafc;
}

.resident-kindness {
    font-size: 13px;
    color: #cbd5f5;
}

.resident-kindness span {
    font-weight: 700;
    color: #facc15;
}

.resident-share-controls {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.resident-share-controls.hidden {
    display: none;
}

.resident-share-btn {
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, #34d399, #10b981);
    color: #0f172a;
    font-weight: 700;
    font-size: 14px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.resident-share-btn.resident-share-btn--off {
    border: none;
    box-shadow: none;
}

.resident-share-btn.resident-share-btn--off:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 12px 28px rgba(16, 185, 129, 0.35);
}

.resident-status-input-group {
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 8px 6px 12px;
    border-radius: 12px;
    border: 1px solid rgba(148, 163, 184, 0.3);
    background: rgba(15, 23, 42, 0.45);
    box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.2);
    flex: 1 1 40px;
    width: 100%;
}

.resident-status-label {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

#resident-status-input {
    background: transparent;
    border: none;
    color: #f8fafc;
    font-size: 12px;
    flex: 1 1 auto;
    min-width: 0;
}

#resident-status-input::placeholder {
    color: rgba(226, 232, 240, 0.6);
}

#resident-status-input:focus {
    outline: none;
}

.resident-status-save-btn {
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
    border: 1px solid #3f7bff;
    background: linear-gradient(135deg, #52a4ff, #3f7bff);
    color: #f8fafc;
    transition: background 0.2s ease, transform 0.1s ease;
}

.resident-status-save-btn:hover:not(:disabled) {
    border-color: #316acc;
    background: linear-gradient(135deg, #3f8bf5, #316acc);
}

.resident-status-save-btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.resident-status-message {
    display: none;
    font-size: 12px;
    padding: 8px 10px;
    border-radius: 8px;
    background: rgba(148, 163, 184, 0.12);
    color: #cbd5f5;
    margin-top: 4px;
}

.resident-status-message.resident-status-message--visible {
    display: block;
}

.resident-status-message.resident-status-message--success {
    background: rgba(52, 211, 153, 0.18);
    color: #bbf7d0;
}

.resident-status-message.resident-status-message--error {
    background: rgba(248, 113, 113, 0.18);
    color: #fecaca;
}

.resident-edit-toggle {
    margin-top: 10px;
}

.resident-edit-form {
    margin-top: 12px;
    padding: 14px;
    border-radius: 12px;
    background: rgba(15, 23, 42, 0.68);
    border: 1px solid rgba(148, 163, 184, 0.25);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.resident-edit-form.hidden {
    display: none;
}

.resident-edit-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.resident-edit-field label,
.resident-edit-label {
    font-size: 12px;
    font-weight: 600;
    color: #e2e8f0;
}

.resident-edit-field input[type="text"] {
    border-radius: 8px;
    border: 1px solid rgba(148, 163, 184, 0.35);
    background: rgba(15, 23, 42, 0.4);
    color: #f8fafc;
    padding: 8px 10px;
    font-size: 13px;
    outline: none;
}

.resident-edit-field input[type="text"]:focus {
    border-color: #38bdf8;
    box-shadow: 0 0 0 2px rgba(56, 189, 248, 0.25);
}

.resident-edit-photo-field {
    gap: 8px;
}

.resident-edit-photo-wrapper {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.resident-edit-photo-preview {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    border: 2px dashed rgba(148, 163, 184, 0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.6);
    color: #94a3b8;
    font-size: 11px;
    text-align: center;
    overflow: hidden;
    position: relative;
    transition: border-color 0.2s ease, color 0.2s ease;
}

.resident-edit-photo-preview[data-has-image="true"] {
    border-style: solid;
    border-color: #38bdf8;
    color: transparent;
}

.resident-edit-photo-preview__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
}

.resident-edit-photo-preview[data-has-image="true"] .resident-edit-photo-preview__image {
    display: block;
}

.resident-edit-photo-preview__placeholder {
    padding: 0 10px;
    line-height: 1.35;
}

.resident-edit-photo-preview[data-has-image="true"] .resident-edit-photo-preview__placeholder {
    display: none;
}

.resident-edit-photo-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.resident-edit-photo-upload {
    position: relative;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(56, 189, 248, 0.18);
    border: 1px solid rgba(56, 189, 248, 0.35);
    color: #bae6fd;
    font-size: 12px;
    font-weight: 600;
    padding: 6px 14px;
    cursor: pointer;
}

.resident-edit-photo-upload input[type="file"] {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
}

.resident-edit-remove-btn {
    border-radius: 999px;
    border: 1px solid rgba(248, 113, 113, 0.35);
    background: rgba(248, 113, 113, 0.12);
    color: #fecaca;
    font-size: 12px;
    font-weight: 600;
    padding: 6px 14px;
}

.resident-edit-remove-btn:hover {
    background: rgba(248, 113, 113, 0.22);
}

.resident-edit-hint {
    font-size: 11px;
    color: #94a3b8;
    margin: 0;
}

.resident-edit-message {
    font-size: 12px;
    padding: 8px 10px;
    border-radius: 8px;
    background: rgba(148, 163, 184, 0.12);
    color: #cbd5f5;
    display: none;
}

.resident-edit-message.resident-edit-message--visible {
    display: block;
}

.resident-edit-message.resident-edit-message--success {
    background: rgba(52, 211, 153, 0.18);
    color: #bbf7d0;
}

.resident-edit-message.resident-edit-message--error {
    background: rgba(248, 113, 113, 0.18);
    color: #fecaca;
}

.resident-edit-actions {
    display: flex;
    gap: 10px;
}

.resident-edit-submit-btn,
.resident-edit-cancel-btn {
    padding: 6px 16px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
}

.resident-edit-submit-btn {
    border: 1px solid rgba(56, 189, 248, 0.45);
    background: linear-gradient(135deg, rgba(56, 189, 248, 0.35), rgba(59, 130, 246, 0.35));
    color: #e0f2fe;
}

.resident-edit-submit-btn:hover {
    border-color: rgba(56, 189, 248, 0.75);
    background: linear-gradient(135deg, rgba(56, 189, 248, 0.5), rgba(59, 130, 246, 0.55));
}

.resident-edit-cancel-btn {
    border: 1px solid rgba(148, 163, 184, 0.35);
    background: rgba(148, 163, 184, 0.12);
    color: #cbd5f5;
}

.resident-edit-cancel-btn:hover {
    background: rgba(148, 163, 184, 0.22);
}

.resident-share-status {
    font-size: 12px;
    color: #34d399;
}

.resident-share-status--off {
    color: #f97316;
}

.resident-logout-btn {
    align-self: flex-start;
    margin-top: 4px;
    padding: 6px 12px;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.35);
    background: rgba(148, 163, 184, 0.12);
    color: #e2e8f0;
    font-size: 12px;
    font-weight: 600;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.resident-logout-btn:hover {
    background: rgba(148, 163, 184, 0.25);
    border-color: rgba(148, 163, 184, 0.55);
}

.resident-auth-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.resident-auth-links.hidden {
    display: none;
}

.resident-menu-link {
    text-decoration: none;
}

.resident-menu-link:hover {
    text-decoration: none;
    background: rgba(96, 165, 250, 0.2);
    border-color: rgba(96, 165, 250, 0.4);
}

.resident-prompt,
.liveSeller-prompt {
    margin: 6px 0 0;
    font-size: 12px;
    color: #94a3b8;
}

.live-seller-marker {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #1f2937, #0f172a);
    border: 2px solid #f8fafc;
    box-sizing: border-box;
    filter: drop-shadow(0 6px 12px rgba(15, 23, 42, 0.45));
}

.live-seller-marker__photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.live-seller-marker__fallback {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 20px;
    color: #f8fafc;
    background: linear-gradient(135deg, #2563eb, #7c3aed);
}

.live-seller-popup {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    max-width: 240px;
    color: #0f172a;
    font-family: sans-serif;
}

.live-seller-popup-photo {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    object-fit: cover;
}

.live-seller-popup-body {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.live-seller-popup-name-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.live-seller-popup-actions {
    margin-top: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.live-seller-popup-note {
    font-size: 12px;
    color: #64748b;
    margin-top: 6px;
}

.live-seller-menu-toggle {
    border: none;
    background: linear-gradient(135deg, #2563eb, #7c3aed);
    color: #f8fafc;
    padding: 6px 10px;
    border-radius: 999px;
    font-weight: 600;
    font-size: 12px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.live-seller-menu-toggle:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 12px rgba(37, 99, 235, 0.3);
}

.live-seller-popup-menu {
    margin-top: 10px;
    display: flex;
    gap: 8px;
    overflow-x: auto;
}

.live-seller-popup-menu.hidden {
    display: none;
}

.live-seller-popup-menu img {
    width: 72px;
    height: 72px;
    border-radius: 12px;
    object-fit: cover;
    flex: 0 0 auto;
    border: 1px solid rgba(148, 163, 184, 0.35);
    background: rgba(241, 245, 249, 0.8);
}

.live-seller-photo-overlay {
    position: fixed;
    inset: 0;
    z-index: 2200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: rgba(15, 23, 42, 0.75);
    backdrop-filter: blur(6px);
    transition: opacity 0.2s ease;
}

.live-seller-photo-overlay.hidden {
    opacity: 0;
    pointer-events: none;
}

body.live-seller-photo-overlay-open {
    overflow: hidden;
}

.live-seller-photo-overlay-content {
    position: relative;
    width: 100%;
    max-width: min(96vw, 640px);
    max-height: 92vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.live-seller-photo-overlay-close {
    align-self: flex-end;
    border: none;
    background: rgba(15, 23, 42, 0.85);
    color: #e2e8f0;
    padding: 6px 12px;
    border-radius: 999px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease;
}

.live-seller-photo-overlay-close:hover {
    background: rgba(15, 23, 42, 0.95);
}

.live-seller-photo-overlay-images {
    width: 100%;
    max-height: inherit;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 4px;
}

.live-seller-photo-overlay-images img {
    width: 100%;
    border-radius: 16px;
    object-fit: contain;
    max-height: calc(92vh - 64px);
    background: #f8fafc;
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.45);
}

.pin-image-overlay {
    position: fixed;
    inset: 0;
    z-index: 2300;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: rgba(15, 23, 42, 0.78);
    backdrop-filter: blur(6px);
    transition: opacity 0.2s ease;
}

.pin-image-overlay.hidden {
    opacity: 0;
    pointer-events: none;
}

body.pin-image-overlay-open {
    overflow: hidden;
}

.pin-image-overlay__content {
    width: min(96vw, 720px);
    max-height: 92vh;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.pin-image-overlay__close {
    align-self: flex-end;
    border: none;
    background: rgba(15, 23, 42, 0.85);
    color: #e2e8f0;
    padding: 6px 14px;
    border-radius: 999px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease;
}

.pin-image-overlay__close:hover,
.pin-image-overlay__close:focus-visible {
    background: rgba(15, 23, 42, 0.95);
    outline: none;
}

.pin-image-overlay__frame {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.4);
    border-radius: 18px;
    padding: clamp(12px, 4vw, 24px);
}

.pin-image-overlay__image {
    width: 100%;
    max-height: calc(92vh - 140px);
    object-fit: contain;
    border-radius: 14px;
    background: rgba(248, 250, 252, 0.9);
    box-shadow: 0 16px 40px rgba(15, 23, 42, 0.5);
}

.pin-image-overlay__nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    min-height: 42px;
}

.pin-image-overlay__counter {
    font-size: 0.95rem;
    font-weight: 600;
    color: #e2e8f0;
    letter-spacing: 0.02em;
}

.pin-image-overlay__nav-btn {
    border: none;
    background: rgba(15, 23, 42, 0.85);
    color: #e2e8f0;
    width: 42px;
    height: 42px;
    border-radius: 999px;
    font-size: 1.25rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

.pin-image-overlay__nav-btn:hover:not(.pin-image-overlay__nav-btn--disabled),
.pin-image-overlay__nav-btn:focus-visible:not(.pin-image-overlay__nav-btn--disabled) {
    background: rgba(15, 23, 42, 0.95);
    transform: translateY(-1px);
    outline: none;
}

.pin-image-overlay__nav-btn--disabled,
.pin-image-overlay__nav-btn:disabled {
    opacity: 0.4;
    cursor: default;
    transform: none;
}

.pin-image-overlay__nav-btn--prev {
    padding-right: 2px;
}

.pin-image-overlay__nav-btn--next {
    padding-left: 2px;
}

.live-seller-edit-btn {
    border: none;
    background: linear-gradient(135deg, #2563eb, #7c3aed);
    color: #f8fafc;
    padding: 8px 12px;
    border-radius: 999px;
    font-weight: 600;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.live-seller-edit-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 12px rgba(37, 99, 235, 0.3);
}

.live-seller-edit-modal {
    width: min(480px, 92vw);
    position: relative;
}

.live-seller-edit-modal h2 {
    margin: 0 0 16px;
    font-size: 20px;
    color: #0f172a;
}

.live-seller-edit-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.live-seller-edit-field label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 6px;
}

.live-seller-edit-field input[type="text"],
.live-seller-edit-field input[type="tel"],
.live-seller-edit-field textarea {
    width: 100%;
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid rgba(148, 163, 184, 0.6);
    background: rgba(255, 255, 255, 0.9);
    color: #0f172a;
    font-size: 14px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    resize: vertical;
}

.live-seller-edit-field input[type="text"]:focus,
.live-seller-edit-field input[type="tel"]:focus,
.live-seller-edit-field textarea:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.live-seller-edit-field textarea {
    min-height: 96px;
}

.live-seller-edit-field--toggle {
    padding: 12px;
    border-radius: 12px;
    border: 1px dashed rgba(148, 163, 184, 0.4);
    background: rgba(248, 250, 252, 0.7);
}

.live-seller-edit-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    font-weight: 600;
    color: #1f2937;
}

.live-seller-edit-toggle input {
    width: 18px;
    height: 18px;
}

.live-seller-edit-toggle-hint {
    margin: 4px 0 0;
    font-size: 12px;
    color: #64748b;
}

.live-seller-edit-photo-field {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.live-seller-edit-photo-preview {
    width: 120px;
    height: 120px;
    border-radius: 20px;
    overflow: hidden;
    border: 2px solid rgba(15, 23, 42, 0.08);
    background: rgba(226, 232, 240, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.live-seller-edit-photo-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
}

#live-seller-edit-photo-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    font-size: 13px;
    color: #475569;
    text-align: center;
    padding: 0 12px;
}

.live-seller-edit-photo-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.live-seller-edit-photo-hint {
    margin: 0;
    font-size: 12px;
    color: #64748b;
}

.live-seller-edit-menu-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    min-height: 96px;
}

.live-seller-edit-menu-item {
    position: relative;
    width: 96px;
    height: 96px;
    border-radius: 16px;
    overflow: hidden;
    background: rgba(226, 232, 240, 0.6);
    border: 2px solid rgba(148, 163, 184, 0.25);
}

.live-seller-edit-menu-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.live-seller-edit-menu-remove {
    position: absolute;
    top: 4px;
    right: 4px;
    border: none;
    width: 24px;
    height: 24px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.65);
    color: #f8fafc;
    font-size: 16px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.live-seller-edit-menu-remove:hover {
    background: rgba(15, 23, 42, 0.85);
}

.live-seller-edit-menu-empty {
    font-size: 12px;
    color: #64748b;
    padding: 8px 0;
}

.live-seller-edit-menu-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    margin-top: 8px;
}

#live-seller-edit-menu-photos {
    font-size: 13px;
}

.live-seller-edit-message {
    display: none;
    padding: 10px 12px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
}

.live-seller-edit-message.success {
    display: block;
    background: rgba(16, 185, 129, 0.12);
    color: #047857;
    border: 1px solid rgba(16, 185, 129, 0.4);
}

.live-seller-edit-message.error {
    display: block;
    background: rgba(248, 113, 113, 0.12);
    color: #b91c1c;
    border: 1px solid rgba(248, 113, 113, 0.35);
}

#live-seller-edit-photo {
    font-size: 13px;
}

#live-seller-edit-submit {
    align-self: flex-end;
}

.live-seller-phone-note {
    font-size: 12px;
    color: #64748b;
    margin-top: 4px;
}

.live-seller-phone-note.hidden {
    display: none;
}

.live-seller-popup-name {
    font-weight: 700;
    font-size: 15px;
}

.live-seller-verified-badge {
    padding: 2px 10px;
    border-radius: 999px;
    background: rgba(34, 197, 94, 0.16);
    color: #166534;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.live-seller-popup-brand {
    font-size: 13px;
    color: #475569;
}

.live-seller-popup-desc {
    font-size: 12px;
    color: #64748b;
    line-height: 1.4;
    white-space: pre-line;
}

.live-seller-popup-contact {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-top: 4px;
    padding: 8px 10px;
    border-radius: 8px;
    background: #22c55e;
    color: #0f172a;
    font-weight: 700;
    font-size: 12px;
    text-decoration: none;
}

.live-seller-popup-contact:hover {
    background: #16a34a;
    color: #fff;
}

.live-seller-verification {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 6px;
}

.live-seller-vote-count {
    font-size: 12px;
    font-weight: 600;
    color: #334155;
}

.live-seller-verify-btn {
    border: none;
    border-radius: 10px;
    padding: 8px 12px;
    background: linear-gradient(135deg, #38bdf8, #6366f1);
    color: #0f172a;
    font-weight: 600;
    font-size: 12px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.live-seller-verify-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 24px rgba(99, 102, 241, 0.24);
}

.live-seller-verify-btn:disabled {
    cursor: not-allowed;
    opacity: 0.7;
    transform: none;
    box-shadow: none;
}

.live-seller-vote-status {
    font-size: 12px;
    font-weight: 600;
    color: #16a34a;
}

@media (max-width: 640px) {
    :root {
        --top-control-height: 44px;
        --action-menu-toggle-size: var(--top-control-height);
        --pin-list-panel-width: var(--bottom-nav-width);
        --bottom-nav-height: 58px;
    }
    .pin-list-panel {
        left: 50%;
        right: auto;
        transform: translateX(-50%);
        align-items: center;
    }
    .action-menu {
        right: 10px;
    }
    .bottom-nav {
        padding: 8px;
        gap: 4px;
    }
    .bottom-nav__btn {
        font-size: 11px;
        padding: 6px 4px;
        min-height: 36px;
    }
    .bottom-nav .action-menu-toggle__avatar {
        width: 24px;
        height: 24px;
        font-size: 12px;
    }
    .bottom-nav .action-menu-toggle .bottom-nav__label {
        display: none;
    }
    .pin-list-search-wrapper {
        width: var(--pin-list-panel-width);
    }
    .pin-list-search-field {
        width: 100%;
        max-width: var(--pin-list-panel-width);
    }
    .action-menu-toggle {
        width: var(--action-menu-toggle-size);
        height: var(--action-menu-toggle-size);
    }
    .action-menu-toggle__avatar {
        font-size: 18px;
    }
    .bottom-nav .action-menu-content {
        position: fixed;
        left: 50%;
        right: auto;
        bottom: calc(var(--bottom-nav-offset) + 12px);
        transform: translateX(-50%);
        width: var(--bottom-nav-width);
        max-height: 75vh;
        padding: 24px 16px 24px;
    }
    .live-seller-panel-actions {
        flex-wrap: wrap;
    }
}

@media (min-width: 641px) {
    .bottom-nav .action-menu-content {
        position: fixed;
        left: auto;
        right: calc(12px + var(--safe-right));
        top: auto;
        bottom: calc(var(--bottom-nav-offset) + 12px);
        transform: none;
        width: var(--pin-list-panel-width);
        max-width: var(--pin-list-panel-width);
        max-height: 75vh;
        margin-top: 0;
    }
}

/* Animated user location marker */
.user-marker {
    position: relative;
    width: 22px;
    height: 22px;
}

.user-marker__dot {
    position: absolute;
    inset: 3px; /* creates inner dot */
    background: #4285f4;
    border: 2px solid #ffffff; /* white ring */
    border-radius: 50%;
    box-shadow: 0 0 0 2px rgba(66, 133, 244, 0.15);
}

.user-marker__pulse {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: rgba(66, 133, 244, 0.35);
    animation: user-pulse 2.2s ease-out infinite;
}

@keyframes user-pulse {
    0% { transform: scale(0.6); opacity: 0.8; }
    70% { transform: scale(1.8); opacity: 0; }
    100% { transform: scale(1.8); opacity: 0; }
}

.resident-share-marker {
    position: relative;
    width: 48px;
    height: 62px;
}

.resident-share-marker__pulse {
    position: absolute;
    top: 4px;
    left: 50%;
    width: 44px;
    height: 44px;
    margin-left: -22px;
    border-radius: 50%;
    background: rgba(34, 211, 238, 0.25);
    animation: resident-share-pulse 2.4s ease-out infinite;
    transform-origin: center;
}

.resident-share-marker__avatar {
    position: absolute;
    top: 8px;
    left: 50%;
    width: 36px;
    height: 36px;
    margin-left: -18px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0d9488, #047857);
    border: 2px solid #ecfeff;
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    color: #ecfeff;
    font-weight: 700;
    font-size: 15px;
    text-transform: uppercase;
}

.resident-share-marker__photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
}

.resident-share-marker--with-photo .resident-share-marker__photo {
    display: block;
}

.resident-share-marker--with-photo .resident-share-marker__fallback {
    display: none;
}

.resident-share-marker__fallback {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    letter-spacing: 0.03em;
}

.resident-share-marker__status {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    padding: 4px 8px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.85);
    color: #e0f2fe;
    font-size: 11px;
    line-height: 1.2;
    max-width: 140px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.35);
    pointer-events: none;
}

@keyframes resident-share-pulse {
    0% {
        transform: scale(0.65);
        opacity: 0.8;
    }
    70% {
        transform: scale(1.4);
        opacity: 0;
    }
    100% {
        opacity: 0;
    }
}





.pin-list-popover-body {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
