html, body { height: 100%; margin: 0; font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif; }
#app { display: flex; flex-direction: column; height: 100%; }

#topbar { display: flex; align-items: center; padding: 8px 12px; border-bottom: 1px solid #eee; background: #fff; z-index: 2; }
#topbar .brand { font-weight: 700; }
#topbar .spacer { flex: 1; }
.userbox { display: flex; gap: 8px; align-items: center; }
.userbox img { width: 28px; height: 28px; border-radius: 50%; }
.userbox .link { background: none; border: none; color: #1976d2; cursor: pointer; }

main { position: relative; flex: 1; }
#map { position: absolute; inset: 0; }

.overlay { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background: rgba(255,255,255,0.85); z-index: 2; }
.overlay .card { background: #fff; padding: 24px; border-radius: 12px; box-shadow: 0 10px 30px rgba(0,0,0,0.1); text-align: center; }
.overlay .hint { color: #666; }

.bottombar { position: absolute; left: 0; right: 0; bottom: 0; display: flex; align-items: center; gap: 12px; padding: 10px; background: rgba(255,255,255,0.95); border-top: 1px solid #eee; z-index: 2; }
.bottombar .status { flex: 1; color: #444; }
.bottombar .controls { display: flex; gap: 10px; }

button { font-size: 16px; padding: 12px 16px; border-radius: 10px; border: 1px solid transparent; cursor: pointer; }
button.primary { background: #1976d2; color: #fff; }
button.secondary { background: #fff; color: #1976d2; border-color: #1976d2; }
button:disabled { opacity: 0.6; cursor: not-allowed; }
.hidden { display: none !important; }

@media (max-width: 480px) {
  button { font-size: 15px; padding: 12px 14px; }
}

/* icon-style button for hamburger */
.icon-btn {
        background: #fff;
        color: #333;
        border: 1px solid #ccc;
        border-radius: 8px;
        padding: 10px 12px;
        line-height: 1;
        font-size: 18px;
      }
      
      /* anchor the popup to the controls area */
      .bottombar .controls { position: relative; }
      
      /* popup menu */
      .menu {
        position: absolute;
        right: 0;
        bottom: 52px; /* above the buttons; tweak if needed */
        background: #fff;
        border: 1px solid #e6e6e6;
        border-radius: 10px;
        box-shadow: 0 8px 24px rgba(0,0,0,0.12);
        padding: 6px;
        display: flex;
        flex-direction: column;
        min-width: 180px;
        z-index: 3;
      }
      
      .menu-item {
        background: none;
        border: none;
        text-align: left;
        padding: 10px 12px;
        border-radius: 8px;
        cursor: pointer;
        font-size: 15px;
      }
      .menu-item:hover { background: #f5f5f5; }
      
      .menu-item.danger { color: #c62828; }
      .menu-item.danger:hover { background: #fdecea; }
      
